@@ -47,15 +47,15 @@ describe('Guard', () => {
4747 } )
4848
4949 describe ( 'refine' , ( ) => {
50- it ( 'should accepts valid inputs' , ( ) => {
50+ it ( 'should accept valid inputs' , ( ) => {
5151 const guard = pipe (
5252 G . string ,
5353 G . refine ( ( s ) : s is string => s . length > 0 )
5454 )
5555 assert . strictEqual ( guard . is ( 'a' ) , true )
5656 } )
5757
58- it ( 'should rejects invalid inputs' , ( ) => {
58+ it ( 'should reject invalid inputs' , ( ) => {
5959 const guard = pipe (
6060 G . string ,
6161 G . refine ( ( s ) : s is string => s . length > 0 )
@@ -66,30 +66,30 @@ describe('Guard', () => {
6666 } )
6767
6868 describe ( 'nullable' , ( ) => {
69- it ( 'should accepts valid inputs' , ( ) => {
69+ it ( 'should accept valid inputs' , ( ) => {
7070 const guard = G . nullable ( G . string )
7171 assert . strictEqual ( guard . is ( null ) , true )
7272 assert . strictEqual ( guard . is ( 'a' ) , true )
7373 } )
7474
75- it ( 'should rejects invalid inputs' , ( ) => {
75+ it ( 'should reject invalid inputs' , ( ) => {
7676 const guard = G . nullable ( G . string )
7777 assert . strictEqual ( guard . is ( 1 ) , false )
7878 } )
7979 } )
8080
8181 describe ( 'type' , ( ) => {
82- it ( 'should accepts valid inputs' , ( ) => {
82+ it ( 'should accept valid inputs' , ( ) => {
8383 const guard = G . type ( { a : G . string , b : G . number } )
8484 assert . strictEqual ( guard . is ( { a : 'a' , b : 1 } ) , true )
8585 } )
8686
87- it ( 'should accepts additional fields' , ( ) => {
87+ it ( 'should accept additional fields' , ( ) => {
8888 const guard = G . type ( { a : G . string , b : G . number } )
8989 assert . strictEqual ( guard . is ( { a : 'a' , b : 1 , c : true } ) , true )
9090 } )
9191
92- it ( 'should rejects invalid inputs' , ( ) => {
92+ it ( 'should reject invalid inputs' , ( ) => {
9393 const guard = G . type ( { a : G . string , b : G . number } )
9494 assert . strictEqual ( guard . is ( undefined ) , false )
9595 assert . strictEqual ( guard . is ( { a : 'a' } ) , false )
@@ -118,20 +118,20 @@ describe('Guard', () => {
118118 } )
119119
120120 describe ( 'partial' , ( ) => {
121- it ( 'should accepts valid inputs' , ( ) => {
121+ it ( 'should accept valid inputs' , ( ) => {
122122 const guard = G . partial ( { a : G . string , b : G . number } )
123123 assert . strictEqual ( guard . is ( { a : 'a' , b : 1 } ) , true )
124124 assert . strictEqual ( guard . is ( { a : 'a' } ) , true )
125125 assert . strictEqual ( guard . is ( { b : 1 } ) , true )
126126 assert . strictEqual ( guard . is ( { } ) , true )
127127 } )
128128
129- it ( 'should accepts additional fields' , ( ) => {
129+ it ( 'should accept additional fields' , ( ) => {
130130 const guard = G . partial ( { a : G . string , b : G . number } )
131131 assert . strictEqual ( guard . is ( { a : 'a' , b : 1 , c : true } ) , true )
132132 } )
133133
134- it ( 'should rejects invalid inputs' , ( ) => {
134+ it ( 'should reject invalid inputs' , ( ) => {
135135 const guard = G . partial ( { a : G . string , b : G . number } )
136136 assert . strictEqual ( guard . is ( undefined ) , false )
137137 assert . strictEqual ( guard . is ( { a : 'a' , b : 'b' } ) , false )
@@ -152,75 +152,75 @@ describe('Guard', () => {
152152 } )
153153
154154 describe ( 'record' , ( ) => {
155- it ( 'should accepts valid inputs' , ( ) => {
155+ it ( 'should accept valid inputs' , ( ) => {
156156 const guard = G . record ( G . string )
157157 assert . strictEqual ( guard . is ( { } ) , true )
158158 assert . strictEqual ( guard . is ( { a : 'a' , b : 'b' } ) , true )
159159 } )
160160
161- it ( 'should rejects invalid inputs' , ( ) => {
161+ it ( 'should reject invalid inputs' , ( ) => {
162162 const guard = G . record ( G . string )
163163 assert . strictEqual ( guard . is ( undefined ) , false )
164164 assert . strictEqual ( guard . is ( { a : 'a' , b : 1 } ) , false )
165165 } )
166166 } )
167167
168168 describe ( 'array' , ( ) => {
169- it ( 'should accepts valid inputs' , ( ) => {
169+ it ( 'should accept valid inputs' , ( ) => {
170170 const guard = G . array ( G . number )
171171 assert . strictEqual ( guard . is ( [ ] ) , true )
172172 assert . strictEqual ( guard . is ( [ 1 , 2 , 3 ] ) , true )
173173 } )
174174
175- it ( 'should rejects invalid inputs' , ( ) => {
175+ it ( 'should reject invalid inputs' , ( ) => {
176176 const guard = G . array ( G . number )
177177 assert . strictEqual ( guard . is ( undefined ) , false )
178178 assert . strictEqual ( guard . is ( [ 'a' ] ) , false )
179179 } )
180180 } )
181181
182182 describe ( 'tuple' , ( ) => {
183- it ( 'should accepts valid inputs' , ( ) => {
183+ it ( 'should accept valid inputs' , ( ) => {
184184 const guard = G . tuple ( G . string , G . number )
185185 assert . strictEqual ( guard . is ( [ 'a' , 1 ] ) , true )
186186 } )
187187
188- it ( 'should rejects invalid inputs' , ( ) => {
188+ it ( 'should reject invalid inputs' , ( ) => {
189189 const guard = G . tuple ( G . string , G . number )
190190 assert . strictEqual ( guard . is ( [ 1 , 2 ] ) , false )
191191 } )
192192
193- it ( 'should rejects additional fields' , ( ) => {
193+ it ( 'should reject additional fields' , ( ) => {
194194 const guard = G . tuple ( G . string , G . number )
195195 assert . strictEqual ( guard . is ( [ 'a' , 1 , true ] ) , false )
196196 } )
197197
198- it ( 'should rejects missing fields' , ( ) => {
198+ it ( 'should reject missing fields' , ( ) => {
199199 const guard = G . tuple ( G . string , G . number )
200200 assert . strictEqual ( guard . is ( [ 'a' ] ) , false )
201201 } )
202202 } )
203203
204204 describe ( 'intersect' , ( ) => {
205- it ( 'should accepts valid inputs' , ( ) => {
205+ it ( 'should accept valid inputs' , ( ) => {
206206 const guard = pipe ( G . type ( { a : G . string } ) , G . intersect ( G . type ( { b : G . number } ) ) )
207207 assert . strictEqual ( guard . is ( { a : 'a' , b : 1 } ) , true )
208208 } )
209209
210- it ( 'should rejects invalid inputs' , ( ) => {
210+ it ( 'should reject invalid inputs' , ( ) => {
211211 const guard = pipe ( G . type ( { a : G . string } ) , G . intersect ( G . type ( { b : G . number } ) ) )
212212 assert . strictEqual ( guard . is ( { a : 'a' } ) , false )
213213 } )
214214 } )
215215
216216 describe ( 'union' , ( ) => {
217- it ( 'should accepts valid inputs' , ( ) => {
217+ it ( 'should accept valid inputs' , ( ) => {
218218 const guard = G . union ( G . string , G . number )
219219 assert . strictEqual ( guard . is ( 'a' ) , true )
220220 assert . strictEqual ( guard . is ( 1 ) , true )
221221 } )
222222
223- it ( 'should rejects invalid inputs' , ( ) => {
223+ it ( 'should reject invalid inputs' , ( ) => {
224224 const guard = G . union ( G . string , G . number )
225225 assert . strictEqual ( guard . is ( undefined ) , false )
226226 } )
@@ -239,12 +239,12 @@ describe('Guard', () => {
239239 } )
240240 )
241241
242- it ( 'should accepts valid inputs' , ( ) => {
242+ it ( 'should accept valid inputs' , ( ) => {
243243 assert . strictEqual ( guard . is ( { a : 1 , b : [ ] } ) , true )
244244 assert . strictEqual ( guard . is ( { a : 1 , b : [ { a : 2 , b : [ ] } ] } ) , true )
245245 } )
246246
247- it ( 'should rejects invalid inputs' , ( ) => {
247+ it ( 'should reject invalid inputs' , ( ) => {
248248 const guard = G . union ( G . string , G . number )
249249 assert . strictEqual ( guard . is ( undefined ) , false )
250250 } )
@@ -253,7 +253,7 @@ describe('Guard', () => {
253253 describe ( 'sum' , ( ) => {
254254 const sum = G . sum ( '_tag' )
255255
256- it ( 'should accepts valid inputs' , ( ) => {
256+ it ( 'should accept valid inputs' , ( ) => {
257257 const guard = sum ( {
258258 A : G . type ( { _tag : G . literal ( 'A' ) , a : G . string } ) ,
259259 B : G . type ( { _tag : G . literal ( 'B' ) , b : G . number } )
@@ -262,7 +262,7 @@ describe('Guard', () => {
262262 assert . deepStrictEqual ( guard . is ( { _tag : 'B' , b : 1 } ) , true )
263263 } )
264264
265- it ( 'should rejects invalid inputs' , ( ) => {
265+ it ( 'should reject invalid inputs' , ( ) => {
266266 const guard = sum ( {
267267 A : G . type ( { _tag : G . literal ( 'A' ) , a : G . string } ) ,
268268 B : G . type ( { _tag : G . literal ( 'B' ) , b : G . number } )
0 commit comments