@@ -47,7 +47,7 @@ discard block |
||
| 47 | 47 | |
| 48 | 48 | $this->expectException(RuntimeException::class); |
| 49 | 49 | $this->expectExceptionMessage('The ' . Fixtures\UntypedCollection::class . ' collection ' . |
| 50 | - 'must contain the T constant.'); |
|
| 50 | + 'must contain the T constant.'); |
|
| 51 | 51 | |
| 52 | 52 | $collection->add(0, new Fixtures\ObjectWithString()); |
| 53 | 53 | } |
@@ -58,7 +58,7 @@ discard block |
||
| 58 | 58 | |
| 59 | 59 | $this->expectException(InvalidArgumentException::class); |
| 60 | 60 | $this->expectExceptionMessage('The ' . Fixtures\ObjectWithStringCollection::class . ' collection ' . |
| 61 | - 'can contain the ' . Fixtures\ObjectWithString::class . ' objects only.'); |
|
| 61 | + 'can contain the ' . Fixtures\ObjectWithString::class . ' objects only.'); |
|
| 62 | 62 | |
| 63 | 63 | $collection->add(0, new Fixtures\ObjectWithInt()); |
| 64 | 64 | } |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | $collection = new Fixtures\UntypedCollection(); |
| 47 | 47 | |
| 48 | 48 | $this->expectException(RuntimeException::class); |
| 49 | - $this->expectExceptionMessage('The ' . Fixtures\UntypedCollection::class . ' collection ' . |
|
| 49 | + $this->expectExceptionMessage('The '.Fixtures\UntypedCollection::class.' collection '. |
|
| 50 | 50 | 'must contain the T constant.'); |
| 51 | 51 | |
| 52 | 52 | $collection->add(0, new Fixtures\ObjectWithString()); |
@@ -57,8 +57,8 @@ discard block |
||
| 57 | 57 | $collection = new Fixtures\ObjectWithStringCollection(); |
| 58 | 58 | |
| 59 | 59 | $this->expectException(InvalidArgumentException::class); |
| 60 | - $this->expectExceptionMessage('The ' . Fixtures\ObjectWithStringCollection::class . ' collection ' . |
|
| 61 | - 'can contain the ' . Fixtures\ObjectWithString::class . ' objects only.'); |
|
| 60 | + $this->expectExceptionMessage('The '.Fixtures\ObjectWithStringCollection::class.' collection '. |
|
| 61 | + 'can contain the '.Fixtures\ObjectWithString::class.' objects only.'); |
|
| 62 | 62 | |
| 63 | 63 | $collection->add(0, new Fixtures\ObjectWithInt()); |
| 64 | 64 | } |
@@ -23,7 +23,7 @@ discard block |
||
| 23 | 23 | { |
| 24 | 24 | $this->expectException(InvalidArgumentException::class); |
| 25 | 25 | $this->expectExceptionMessage('The ' . Hydrator::class . '::hydrate() method ' . |
| 26 | - 'expects an object or name of an existing class.'); |
|
| 26 | + 'expects an object or name of an existing class.'); |
|
| 27 | 27 | |
| 28 | 28 | (new Hydrator)->hydrate('Undefined', []); |
| 29 | 29 | } |
@@ -32,7 +32,7 @@ discard block |
||
| 32 | 32 | { |
| 33 | 33 | $this->expectException(InvalidArgumentException::class); |
| 34 | 34 | $this->expectExceptionMessage('The ' . Fixtures\UninitializableObject::class . ' object ' . |
| 35 | - 'cannot be hydrated because its constructor has required parameters.'); |
|
| 35 | + 'cannot be hydrated because its constructor has required parameters.'); |
|
| 36 | 36 | |
| 37 | 37 | (new Hydrator)->hydrate(Fixtures\UninitializableObject::class, []); |
| 38 | 38 | } |
@@ -41,7 +41,7 @@ discard block |
||
| 41 | 41 | { |
| 42 | 42 | $this->expectException(InvalidArgumentException::class); |
| 43 | 43 | $this->expectExceptionMessage('The ' . Hydrator::class . '::hydrate(data) parameter ' . |
| 44 | - 'expects an associative array or object.'); |
|
| 44 | + 'expects an associative array or object.'); |
|
| 45 | 45 | |
| 46 | 46 | (new Hydrator)->hydrate(Fixtures\ObjectWithString::class, null); |
| 47 | 47 | } |
@@ -65,7 +65,7 @@ discard block |
||
| 65 | 65 | { |
| 66 | 66 | $this->expectException(Exception\UntypedPropertyException::class); |
| 67 | 67 | $this->expectExceptionMessage('The ObjectWithUntypedProperty.value property ' . |
| 68 | - 'is not typed.'); |
|
| 68 | + 'is not typed.'); |
|
| 69 | 69 | |
| 70 | 70 | (new Hydrator)->hydrate(Fixtures\ObjectWithUntypedProperty::class, []); |
| 71 | 71 | } |
@@ -78,7 +78,7 @@ discard block |
||
| 78 | 78 | |
| 79 | 79 | $this->expectException(Exception\UnsupportedPropertyTypeException::class); |
| 80 | 80 | $this->expectExceptionMessage('The ObjectWithIntOrFloat.value property ' . |
| 81 | - 'contains an union type that is not supported.'); |
|
| 81 | + 'contains an union type that is not supported.'); |
|
| 82 | 82 | |
| 83 | 83 | (new Hydrator)->hydrate(Fixtures\ObjectWithIntOrFloat::class, []); |
| 84 | 84 | } |
@@ -105,7 +105,7 @@ discard block |
||
| 105 | 105 | { |
| 106 | 106 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 107 | 107 | $this->expectExceptionMessage('The ObjectWithAnnotatedAlias.value property ' . |
| 108 | - 'is required.'); |
|
| 108 | + 'is required.'); |
|
| 109 | 109 | |
| 110 | 110 | (new Hydrator) |
| 111 | 111 | ->useAnnotations() |
@@ -117,7 +117,7 @@ discard block |
||
| 117 | 117 | { |
| 118 | 118 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 119 | 119 | $this->expectExceptionMessage('The ObjectWithAnnotatedAlias.value property ' . |
| 120 | - 'is required.'); |
|
| 120 | + 'is required.'); |
|
| 121 | 121 | |
| 122 | 122 | (new Hydrator)->hydrate(Fixtures\ObjectWithAnnotatedAlias::class, ['non-normalized-value' => 'foo']); |
| 123 | 123 | } |
@@ -152,7 +152,7 @@ discard block |
||
| 152 | 152 | |
| 153 | 153 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 154 | 154 | $this->expectExceptionMessage('The ObjectWithAttributedAlias.value property ' . |
| 155 | - 'is required.'); |
|
| 155 | + 'is required.'); |
|
| 156 | 156 | |
| 157 | 157 | (new Hydrator) |
| 158 | 158 | ->aliasSupport(false) |
@@ -163,7 +163,7 @@ discard block |
||
| 163 | 163 | { |
| 164 | 164 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 165 | 165 | $this->expectExceptionMessage('The ObjectWithString.value property ' . |
| 166 | - 'is required.'); |
|
| 166 | + 'is required.'); |
|
| 167 | 167 | |
| 168 | 168 | (new Hydrator)->hydrate(Fixtures\ObjectWithString::class, []); |
| 169 | 169 | } |
@@ -172,7 +172,7 @@ discard block |
||
| 172 | 172 | { |
| 173 | 173 | $this->expectException(Exception\UnsupportedPropertyTypeException::class); |
| 174 | 174 | $this->expectExceptionMessage('The ObjectWithUnsupportedType.value property ' . |
| 175 | - 'contains an unsupported type iterable.'); |
|
| 175 | + 'contains an unsupported type iterable.'); |
|
| 176 | 176 | |
| 177 | 177 | (new Hydrator)->hydrate(Fixtures\ObjectWithUnsupportedType::class, ['value' => false]); |
| 178 | 178 | } |
@@ -227,7 +227,7 @@ discard block |
||
| 227 | 227 | { |
| 228 | 228 | $this->expectException(Exception\InvalidValueException::class); |
| 229 | 229 | $this->expectExceptionMessage('The ObjectWithString.value property ' . |
| 230 | - 'cannot accept null.'); |
|
| 230 | + 'cannot accept null.'); |
|
| 231 | 231 | |
| 232 | 232 | (new Hydrator)->hydrate(Fixtures\ObjectWithString::class, ['value' => null]); |
| 233 | 233 | } |
@@ -407,7 +407,7 @@ discard block |
||
| 407 | 407 | { |
| 408 | 408 | $this->expectException(Exception\InvalidValueException::class); |
| 409 | 409 | $this->expectExceptionMessage('The ObjectWithDateTime.value property ' . |
| 410 | - 'expects a valid date-time string or timestamp.'); |
|
| 410 | + 'expects a valid date-time string or timestamp.'); |
|
| 411 | 411 | |
| 412 | 412 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateTime::class, ['value' => 'foo']); |
| 413 | 413 | } |
@@ -416,7 +416,7 @@ discard block |
||
| 416 | 416 | { |
| 417 | 417 | $this->expectException(Exception\InvalidValueException::class); |
| 418 | 418 | $this->expectExceptionMessage('The ObjectWithDateTimeImmutable.value property ' . |
| 419 | - 'expects a valid date-time string or timestamp.'); |
|
| 419 | + 'expects a valid date-time string or timestamp.'); |
|
| 420 | 420 | |
| 421 | 421 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateTimeImmutable::class, ['value' => 'foo']); |
| 422 | 422 | } |
@@ -432,7 +432,7 @@ discard block |
||
| 432 | 432 | { |
| 433 | 433 | $this->expectException(Exception\InvalidValueException::class); |
| 434 | 434 | $this->expectExceptionMessage('The ObjectWithDateInterval.value property ' . |
| 435 | - 'expects a string.'); |
|
| 435 | + 'expects a string.'); |
|
| 436 | 436 | |
| 437 | 437 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateInterval::class, ['value' => 42]); |
| 438 | 438 | } |
@@ -441,7 +441,7 @@ discard block |
||
| 441 | 441 | { |
| 442 | 442 | $this->expectException(Exception\InvalidValueException::class); |
| 443 | 443 | $this->expectExceptionMessage('The ObjectWithDateInterval.value property ' . |
| 444 | - 'expects a valid date-interval string based on ISO 8601.'); |
|
| 444 | + 'expects a valid date-interval string based on ISO 8601.'); |
|
| 445 | 445 | |
| 446 | 446 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateInterval::class, ['value' => 'foo']); |
| 447 | 447 | } |
@@ -477,7 +477,7 @@ discard block |
||
| 477 | 477 | |
| 478 | 478 | $this->expectException(Exception\InvalidValueException::class); |
| 479 | 479 | $this->expectExceptionMessage('The ObjectWithStringableEnum.value property ' . |
| 480 | - 'expects the following type: string.'); |
|
| 480 | + 'expects the following type: string.'); |
|
| 481 | 481 | |
| 482 | 482 | (new Hydrator)->hydrate(Fixtures\ObjectWithStringableEnum::class, ['value' => 42]); |
| 483 | 483 | } |
@@ -490,8 +490,8 @@ discard block |
||
| 490 | 490 | |
| 491 | 491 | $this->expectException(Exception\InvalidValueException::class); |
| 492 | 492 | $this->expectExceptionMessage('The ObjectWithStringableEnum.value property ' . |
| 493 | - 'expects one of the following values: ' . |
|
| 494 | - \implode(', ', Fixtures\StringableEnum::values()) . '.'); |
|
| 493 | + 'expects one of the following values: ' . |
|
| 494 | + \implode(', ', Fixtures\StringableEnum::values()) . '.'); |
|
| 495 | 495 | |
| 496 | 496 | (new Hydrator)->hydrate(Fixtures\ObjectWithStringableEnum::class, ['value' => 'foo']); |
| 497 | 497 | } |
@@ -532,7 +532,7 @@ discard block |
||
| 532 | 532 | |
| 533 | 533 | $this->expectException(Exception\InvalidValueException::class); |
| 534 | 534 | $this->expectExceptionMessage('The ObjectWithNumerableEnum.value property ' . |
| 535 | - 'expects the following type: int.'); |
|
| 535 | + 'expects the following type: int.'); |
|
| 536 | 536 | |
| 537 | 537 | (new Hydrator)->hydrate(Fixtures\ObjectWithNumerableEnum::class, ['value' => 'foo']); |
| 538 | 538 | } |
@@ -545,8 +545,8 @@ discard block |
||
| 545 | 545 | |
| 546 | 546 | $this->expectException(Exception\InvalidValueException::class); |
| 547 | 547 | $this->expectExceptionMessage('The ObjectWithNumerableEnum.value property ' . |
| 548 | - 'expects one of the following values: ' . |
|
| 549 | - \implode(', ', Fixtures\NumerableEnum::values()) . '.'); |
|
| 548 | + 'expects one of the following values: ' . |
|
| 549 | + \implode(', ', Fixtures\NumerableEnum::values()) . '.'); |
|
| 550 | 550 | |
| 551 | 551 | (new Hydrator)->hydrate(Fixtures\ObjectWithNumerableEnum::class, ['value' => 42]); |
| 552 | 552 | } |
@@ -569,7 +569,7 @@ discard block |
||
| 569 | 569 | { |
| 570 | 570 | $this->expectException(Exception\InvalidValueException::class); |
| 571 | 571 | $this->expectExceptionMessage('The ObjectWithAssociation.value property ' . |
| 572 | - 'expects an associative array or object.'); |
|
| 572 | + 'expects an associative array or object.'); |
|
| 573 | 573 | |
| 574 | 574 | (new Hydrator)->hydrate(Fixtures\ObjectWithAssociation::class, ['value' => 'foo']); |
| 575 | 575 | } |
@@ -606,7 +606,7 @@ discard block |
||
| 606 | 606 | { |
| 607 | 607 | $this->expectException(Exception\InvalidValueException::class); |
| 608 | 608 | $this->expectExceptionMessage('The ObjectWithAssociations.value property ' . |
| 609 | - 'expects an associative array or object.'); |
|
| 609 | + 'expects an associative array or object.'); |
|
| 610 | 610 | |
| 611 | 611 | (new Hydrator)->hydrate(Fixtures\ObjectWithAssociations::class, ['value' => 'foo']); |
| 612 | 612 | } |
@@ -615,7 +615,7 @@ discard block |
||
| 615 | 615 | { |
| 616 | 616 | $this->expectException(Exception\InvalidValueException::class); |
| 617 | 617 | $this->expectExceptionMessage('The ObjectWithAssociations.value[0] property ' . |
| 618 | - 'expects an associative array or object.'); |
|
| 618 | + 'expects an associative array or object.'); |
|
| 619 | 619 | |
| 620 | 620 | (new Hydrator)->hydrate(Fixtures\ObjectWithAssociations::class, ['value' => ['foo']]); |
| 621 | 621 | } |
@@ -22,7 +22,7 @@ discard block |
||
| 22 | 22 | public function testInvalidObject() : void |
| 23 | 23 | { |
| 24 | 24 | $this->expectException(InvalidArgumentException::class); |
| 25 | - $this->expectExceptionMessage('The ' . Hydrator::class . '::hydrate() method ' . |
|
| 25 | + $this->expectExceptionMessage('The '.Hydrator::class.'::hydrate() method '. |
|
| 26 | 26 | 'expects an object or name of an existing class.'); |
| 27 | 27 | |
| 28 | 28 | (new Hydrator)->hydrate('Undefined', []); |
@@ -31,7 +31,7 @@ discard block |
||
| 31 | 31 | public function testUninitializableObject() : void |
| 32 | 32 | { |
| 33 | 33 | $this->expectException(InvalidArgumentException::class); |
| 34 | - $this->expectExceptionMessage('The ' . Fixtures\UninitializableObject::class . ' object ' . |
|
| 34 | + $this->expectExceptionMessage('The '.Fixtures\UninitializableObject::class.' object '. |
|
| 35 | 35 | 'cannot be hydrated because its constructor has required parameters.'); |
| 36 | 36 | |
| 37 | 37 | (new Hydrator)->hydrate(Fixtures\UninitializableObject::class, []); |
@@ -40,7 +40,7 @@ discard block |
||
| 40 | 40 | public function testInvalidData() : void |
| 41 | 41 | { |
| 42 | 42 | $this->expectException(InvalidArgumentException::class); |
| 43 | - $this->expectExceptionMessage('The ' . Hydrator::class . '::hydrate(data) parameter ' . |
|
| 43 | + $this->expectExceptionMessage('The '.Hydrator::class.'::hydrate(data) parameter '. |
|
| 44 | 44 | 'expects an associative array or object.'); |
| 45 | 45 | |
| 46 | 46 | (new Hydrator)->hydrate(Fixtures\ObjectWithString::class, null); |
@@ -64,7 +64,7 @@ discard block |
||
| 64 | 64 | public function testUntypedProperty() : void |
| 65 | 65 | { |
| 66 | 66 | $this->expectException(Exception\UntypedPropertyException::class); |
| 67 | - $this->expectExceptionMessage('The ObjectWithUntypedProperty.value property ' . |
|
| 67 | + $this->expectExceptionMessage('The ObjectWithUntypedProperty.value property '. |
|
| 68 | 68 | 'is not typed.'); |
| 69 | 69 | |
| 70 | 70 | (new Hydrator)->hydrate(Fixtures\ObjectWithUntypedProperty::class, []); |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | } |
| 78 | 78 | |
| 79 | 79 | $this->expectException(Exception\UnsupportedPropertyTypeException::class); |
| 80 | - $this->expectExceptionMessage('The ObjectWithIntOrFloat.value property ' . |
|
| 80 | + $this->expectExceptionMessage('The ObjectWithIntOrFloat.value property '. |
|
| 81 | 81 | 'contains an union type that is not supported.'); |
| 82 | 82 | |
| 83 | 83 | (new Hydrator)->hydrate(Fixtures\ObjectWithIntOrFloat::class, []); |
@@ -104,7 +104,7 @@ discard block |
||
| 104 | 104 | public function testHydrateAnnotatedPropertyWhenDisabledAliasSupport() : void |
| 105 | 105 | { |
| 106 | 106 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 107 | - $this->expectExceptionMessage('The ObjectWithAnnotatedAlias.value property ' . |
|
| 107 | + $this->expectExceptionMessage('The ObjectWithAnnotatedAlias.value property '. |
|
| 108 | 108 | 'is required.'); |
| 109 | 109 | |
| 110 | 110 | (new Hydrator) |
@@ -116,7 +116,7 @@ discard block |
||
| 116 | 116 | public function testHydrateAnnotatedPropertyWhenDisabledAnnotations() : void |
| 117 | 117 | { |
| 118 | 118 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 119 | - $this->expectExceptionMessage('The ObjectWithAnnotatedAlias.value property ' . |
|
| 119 | + $this->expectExceptionMessage('The ObjectWithAnnotatedAlias.value property '. |
|
| 120 | 120 | 'is required.'); |
| 121 | 121 | |
| 122 | 122 | (new Hydrator)->hydrate(Fixtures\ObjectWithAnnotatedAlias::class, ['non-normalized-value' => 'foo']); |
@@ -151,7 +151,7 @@ discard block |
||
| 151 | 151 | } |
| 152 | 152 | |
| 153 | 153 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 154 | - $this->expectExceptionMessage('The ObjectWithAttributedAlias.value property ' . |
|
| 154 | + $this->expectExceptionMessage('The ObjectWithAttributedAlias.value property '. |
|
| 155 | 155 | 'is required.'); |
| 156 | 156 | |
| 157 | 157 | (new Hydrator) |
@@ -162,7 +162,7 @@ discard block |
||
| 162 | 162 | public function testRequiredProperty() : void |
| 163 | 163 | { |
| 164 | 164 | $this->expectException(Exception\MissingRequiredValueException::class); |
| 165 | - $this->expectExceptionMessage('The ObjectWithString.value property ' . |
|
| 165 | + $this->expectExceptionMessage('The ObjectWithString.value property '. |
|
| 166 | 166 | 'is required.'); |
| 167 | 167 | |
| 168 | 168 | (new Hydrator)->hydrate(Fixtures\ObjectWithString::class, []); |
@@ -171,7 +171,7 @@ discard block |
||
| 171 | 171 | public function testUnsupportedPropertyType() : void |
| 172 | 172 | { |
| 173 | 173 | $this->expectException(Exception\UnsupportedPropertyTypeException::class); |
| 174 | - $this->expectExceptionMessage('The ObjectWithUnsupportedType.value property ' . |
|
| 174 | + $this->expectExceptionMessage('The ObjectWithUnsupportedType.value property '. |
|
| 175 | 175 | 'contains an unsupported type iterable.'); |
| 176 | 176 | |
| 177 | 177 | (new Hydrator)->hydrate(Fixtures\ObjectWithUnsupportedType::class, ['value' => false]); |
@@ -226,7 +226,7 @@ discard block |
||
| 226 | 226 | public function testHydrateUnnullablePropertyWithNull() : void |
| 227 | 227 | { |
| 228 | 228 | $this->expectException(Exception\InvalidValueException::class); |
| 229 | - $this->expectExceptionMessage('The ObjectWithString.value property ' . |
|
| 229 | + $this->expectExceptionMessage('The ObjectWithString.value property '. |
|
| 230 | 230 | 'cannot accept null.'); |
| 231 | 231 | |
| 232 | 232 | (new Hydrator)->hydrate(Fixtures\ObjectWithString::class, ['value' => null]); |
@@ -406,7 +406,7 @@ discard block |
||
| 406 | 406 | public function testHydrateDateTimePropertyWithInvalidValue() : void |
| 407 | 407 | { |
| 408 | 408 | $this->expectException(Exception\InvalidValueException::class); |
| 409 | - $this->expectExceptionMessage('The ObjectWithDateTime.value property ' . |
|
| 409 | + $this->expectExceptionMessage('The ObjectWithDateTime.value property '. |
|
| 410 | 410 | 'expects a valid date-time string or timestamp.'); |
| 411 | 411 | |
| 412 | 412 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateTime::class, ['value' => 'foo']); |
@@ -415,7 +415,7 @@ discard block |
||
| 415 | 415 | public function testHydrateDateTimeImmutablePropertyWithInvalidValue() : void |
| 416 | 416 | { |
| 417 | 417 | $this->expectException(Exception\InvalidValueException::class); |
| 418 | - $this->expectExceptionMessage('The ObjectWithDateTimeImmutable.value property ' . |
|
| 418 | + $this->expectExceptionMessage('The ObjectWithDateTimeImmutable.value property '. |
|
| 419 | 419 | 'expects a valid date-time string or timestamp.'); |
| 420 | 420 | |
| 421 | 421 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateTimeImmutable::class, ['value' => 'foo']); |
@@ -431,7 +431,7 @@ discard block |
||
| 431 | 431 | public function testHydrateDateIntervalPropertyWithInvalidValue() : void |
| 432 | 432 | { |
| 433 | 433 | $this->expectException(Exception\InvalidValueException::class); |
| 434 | - $this->expectExceptionMessage('The ObjectWithDateInterval.value property ' . |
|
| 434 | + $this->expectExceptionMessage('The ObjectWithDateInterval.value property '. |
|
| 435 | 435 | 'expects a string.'); |
| 436 | 436 | |
| 437 | 437 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateInterval::class, ['value' => 42]); |
@@ -440,7 +440,7 @@ discard block |
||
| 440 | 440 | public function testHydrateDateIntervalPropertyWithInvalidFormat() : void |
| 441 | 441 | { |
| 442 | 442 | $this->expectException(Exception\InvalidValueException::class); |
| 443 | - $this->expectExceptionMessage('The ObjectWithDateInterval.value property ' . |
|
| 443 | + $this->expectExceptionMessage('The ObjectWithDateInterval.value property '. |
|
| 444 | 444 | 'expects a valid date-interval string based on ISO 8601.'); |
| 445 | 445 | |
| 446 | 446 | (new Hydrator)->hydrate(Fixtures\ObjectWithDateInterval::class, ['value' => 'foo']); |
@@ -476,7 +476,7 @@ discard block |
||
| 476 | 476 | } |
| 477 | 477 | |
| 478 | 478 | $this->expectException(Exception\InvalidValueException::class); |
| 479 | - $this->expectExceptionMessage('The ObjectWithStringableEnum.value property ' . |
|
| 479 | + $this->expectExceptionMessage('The ObjectWithStringableEnum.value property '. |
|
| 480 | 480 | 'expects the following type: string.'); |
| 481 | 481 | |
| 482 | 482 | (new Hydrator)->hydrate(Fixtures\ObjectWithStringableEnum::class, ['value' => 42]); |
@@ -489,9 +489,9 @@ discard block |
||
| 489 | 489 | } |
| 490 | 490 | |
| 491 | 491 | $this->expectException(Exception\InvalidValueException::class); |
| 492 | - $this->expectExceptionMessage('The ObjectWithStringableEnum.value property ' . |
|
| 493 | - 'expects one of the following values: ' . |
|
| 494 | - \implode(', ', Fixtures\StringableEnum::values()) . '.'); |
|
| 492 | + $this->expectExceptionMessage('The ObjectWithStringableEnum.value property '. |
|
| 493 | + 'expects one of the following values: '. |
|
| 494 | + \implode(', ', Fixtures\StringableEnum::values()).'.'); |
|
| 495 | 495 | |
| 496 | 496 | (new Hydrator)->hydrate(Fixtures\ObjectWithStringableEnum::class, ['value' => 'foo']); |
| 497 | 497 | } |
@@ -531,7 +531,7 @@ discard block |
||
| 531 | 531 | } |
| 532 | 532 | |
| 533 | 533 | $this->expectException(Exception\InvalidValueException::class); |
| 534 | - $this->expectExceptionMessage('The ObjectWithNumerableEnum.value property ' . |
|
| 534 | + $this->expectExceptionMessage('The ObjectWithNumerableEnum.value property '. |
|
| 535 | 535 | 'expects the following type: int.'); |
| 536 | 536 | |
| 537 | 537 | (new Hydrator)->hydrate(Fixtures\ObjectWithNumerableEnum::class, ['value' => 'foo']); |
@@ -544,9 +544,9 @@ discard block |
||
| 544 | 544 | } |
| 545 | 545 | |
| 546 | 546 | $this->expectException(Exception\InvalidValueException::class); |
| 547 | - $this->expectExceptionMessage('The ObjectWithNumerableEnum.value property ' . |
|
| 548 | - 'expects one of the following values: ' . |
|
| 549 | - \implode(', ', Fixtures\NumerableEnum::values()) . '.'); |
|
| 547 | + $this->expectExceptionMessage('The ObjectWithNumerableEnum.value property '. |
|
| 548 | + 'expects one of the following values: '. |
|
| 549 | + \implode(', ', Fixtures\NumerableEnum::values()).'.'); |
|
| 550 | 550 | |
| 551 | 551 | (new Hydrator)->hydrate(Fixtures\ObjectWithNumerableEnum::class, ['value' => 42]); |
| 552 | 552 | } |
@@ -568,7 +568,7 @@ discard block |
||
| 568 | 568 | public function testHydrateAssociatedPropertyWithInvalidData() : void |
| 569 | 569 | { |
| 570 | 570 | $this->expectException(Exception\InvalidValueException::class); |
| 571 | - $this->expectExceptionMessage('The ObjectWithAssociation.value property ' . |
|
| 571 | + $this->expectExceptionMessage('The ObjectWithAssociation.value property '. |
|
| 572 | 572 | 'expects an associative array or object.'); |
| 573 | 573 | |
| 574 | 574 | (new Hydrator)->hydrate(Fixtures\ObjectWithAssociation::class, ['value' => 'foo']); |
@@ -605,7 +605,7 @@ discard block |
||
| 605 | 605 | public function testHydrateAssociationCollectionPropertyWithInvalidData() : void |
| 606 | 606 | { |
| 607 | 607 | $this->expectException(Exception\InvalidValueException::class); |
| 608 | - $this->expectExceptionMessage('The ObjectWithAssociations.value property ' . |
|
| 608 | + $this->expectExceptionMessage('The ObjectWithAssociations.value property '. |
|
| 609 | 609 | 'expects an associative array or object.'); |
| 610 | 610 | |
| 611 | 611 | (new Hydrator)->hydrate(Fixtures\ObjectWithAssociations::class, ['value' => 'foo']); |
@@ -614,7 +614,7 @@ discard block |
||
| 614 | 614 | public function testHydrateAssociationCollectionPropertyWithInvalidChild() : void |
| 615 | 615 | { |
| 616 | 616 | $this->expectException(Exception\InvalidValueException::class); |
| 617 | - $this->expectExceptionMessage('The ObjectWithAssociations.value[0] property ' . |
|
| 617 | + $this->expectExceptionMessage('The ObjectWithAssociations.value[0] property '. |
|
| 618 | 618 | 'expects an associative array or object.'); |
| 619 | 619 | |
| 620 | 620 | (new Hydrator)->hydrate(Fixtures\ObjectWithAssociations::class, ['value' => ['foo']]); |
@@ -6,5 +6,5 @@ |
||
| 6 | 6 | |
| 7 | 7 | final class ObjectWithIntOrFloat |
| 8 | 8 | { |
| 9 | - public int|float $value; |
|
| 9 | + public int | float $value; |
|
| 10 | 10 | } |