@@ -25,15 +25,15 @@ test('without items', function () {
2525
2626 checkValidationErrors (function () use ($ schema ) {
2727 (new Processor )->process ($ schema , 'one ' );
28- }, ["The option expects to be array, string 'one' given. " ]);
28+ }, ["The option expects to be array, 'one' given. " ]);
2929
3030 checkValidationErrors (function () use ($ schema ) {
3131 (new Processor )->process ($ schema , true );
32- }, ['The option expects to be array, bool given. ' ]);
32+ }, ['The option expects to be array, true given. ' ]);
3333
3434 checkValidationErrors (function () use ($ schema ) {
3535 (new Processor )->process ($ schema , 123 );
36- }, ['The option expects to be array, int 123 given. ' ]);
36+ }, ['The option expects to be array, 123 given. ' ]);
3737
3838 Assert::equal ((object ) [], (new Processor )->process ($ schema , null ));
3939});
@@ -48,7 +48,7 @@ test('accepts object', function () {
4848
4949 checkValidationErrors (function () use ($ schema ) {
5050 (new Processor )->process ($ schema , (object ) ['a ' => 1 ]);
51- }, ["The option 'a' expects to be string, int 1 given. " ]);
51+ }, ["The option 'a' expects to be string, 1 given. " ]);
5252
5353 $ schema = Expect::structure (['a ' => Expect::string ()->before ('strrev ' )]);
5454
@@ -143,7 +143,7 @@ test('with indexed item', function () {
143143 }, [
144144 "Unexpected option '1'. " ,
145145 "Unexpected option '2'. " ,
146- "The option '0' expects to be string, int 1 given. " ,
146+ "The option '0' expects to be string, 1 given. " ,
147147 ]);
148148
149149 Assert::equal (
@@ -194,7 +194,7 @@ test('with indexed item & otherItems', function () {
194194
195195 checkValidationErrors (function () use ($ processor , $ schema ) {
196196 $ processor ->process ($ schema , [1 , 2 , 3 ]);
197- }, ["The option '0' expects to be string, int 1 given. " ]);
197+ }, ["The option '0' expects to be string, 1 given. " ]);
198198
199199 Assert::equal (
200200 (object ) [
@@ -238,7 +238,7 @@ test('item with default value', function () {
238238
239239 checkValidationErrors (function () use ($ schema ) {
240240 (new Processor )->process ($ schema , ['b ' => 123 ]);
241- }, ["The option 'b' expects to be string, int 123 given. " ]);
241+ }, ["The option 'b' expects to be string, 123 given. " ]);
242242
243243 checkValidationErrors (function () use ($ schema ) {
244244 (new Processor )->process ($ schema , ['b ' => null ]);
@@ -257,7 +257,7 @@ test('item without default value', function () {
257257
258258 checkValidationErrors (function () use ($ schema ) {
259259 (new Processor )->process ($ schema , ['b ' => 123 ]);
260- }, ["The option 'b' expects to be string, int 123 given. " ]);
260+ }, ["The option 'b' expects to be string, 123 given. " ]);
261261
262262 checkValidationErrors (function () use ($ schema ) {
263263 (new Processor )->process ($ schema , ['b ' => null ]);
@@ -301,7 +301,7 @@ test('other items', function () {
301301
302302 checkValidationErrors (function () use ($ schema ) {
303303 (new Processor )->process ($ schema , ['other ' => 123 ]);
304- }, ["The option 'other' expects to be string, int 123 given. " ]);
304+ }, ["The option 'other' expects to be string, 123 given. " ]);
305305});
306306
307307
@@ -331,7 +331,7 @@ test('structure items', function () {
331331 checkValidationErrors (function () use ($ schema ) {
332332 (new Processor )->process ($ schema , ['a ' => 'val ' ]);
333333 }, [
334- "The option 'a' expects to be array, string 'val' given. " ,
334+ "The option 'a' expects to be array, 'val' given. " ,
335335 "The mandatory option 'b › y' is missing. " ,
336336 ]);
337337
@@ -341,15 +341,15 @@ test('structure items', function () {
341341
342342 checkValidationErrors (function () use ($ schema ) {
343343 (new Processor )->process ($ schema , ['b ' => 123 ]);
344- }, ["The option 'b' expects to be array, int 123 given. " ]);
344+ }, ["The option 'b' expects to be array, 123 given. " ]);
345345
346346 checkValidationErrors (function () use ($ schema ) {
347347 (new Processor )->process ($ schema , ['b ' => null ]);
348348 }, ["The mandatory option 'b › y' is missing. " ]);
349349
350350 checkValidationErrors (function () use ($ schema ) {
351351 (new Processor )->process ($ schema , ['b ' => 'val ' ]);
352- }, ["The option 'b' expects to be array, string 'val' given. " ]);
352+ }, ["The option 'b' expects to be array, 'val' given. " ]);
353353
354354 checkValidationErrors (function () use ($ schema ) {
355355 (new Processor )->process ($ schema , ['b ' => ['x ' => 'val ' ]]);
@@ -368,7 +368,7 @@ test('structure items', function () {
368368
369369 checkValidationErrors (function () use ($ schema ) {
370370 (new Processor )->process ($ schema , ['b ' => ['y ' => 123 ]]);
371- }, ["The option 'b › y' expects to be string, int 123 given. " ]);
371+ }, ["The option 'b › y' expects to be string, 123 given. " ]);
372372
373373 Assert::equal (
374374 (object ) ['a ' => (object ) ['x ' => 'defval ' ], 'b ' => (object ) ['y ' => 'val ' ]],
0 commit comments