File tree Expand file tree Collapse file tree 7 files changed +15
-15
lines changed
tests/Unit/MartinGeorgiev/Doctrine/DBAL/Types Expand file tree Collapse file tree 7 files changed +15
-15
lines changed Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ public static function provideValidTransformations(): array
7777 }
7878
7979 #[Test]
80- public function throws_invalid_argument_exception_when_php_value_is_not_array (): void
80+ public function throws_exception_when_php_value_is_not_array (): void
8181 {
8282 $ this ->expectException (\InvalidArgumentException::class);
8383 $ this ->expectExceptionMessageMatches ('/Given PHP value content type is not PHP array. Instead it is "\w+"./ ' );
Original file line number Diff line number Diff line change @@ -112,7 +112,7 @@ public static function provideInvalidValues(): array
112112 }
113113
114114 #[Test]
115- public function transform_array_item_for_php_handles_valid_string (): void
115+ public function can_transform_array_item_for_php_with_valid_string (): void
116116 {
117117 $ this ->assertSame ('valid_address ' , $ this ->fixture ->transformArrayItemForPHP ('"valid_address" ' ));
118118 }
Original file line number Diff line number Diff line change @@ -171,7 +171,7 @@ public function throws_exception_for_malformed_point_strings_in_database(): void
171171 }
172172
173173 #[Test]
174- public function handles_edge_case_with_empty_and_malformed_arrays (): void
174+ public function can_handle_edge_case_with_empty_and_malformed_arrays (): void
175175 {
176176 $ result1 = $ this ->fixture ->convertToPHPValue ('{} ' , $ this ->platform );
177177 $ result2 = $ this ->fixture ->convertToPHPValue ('{invalid} ' , $ this ->platform );
@@ -193,22 +193,22 @@ public function can_return_empty_array_for_non_standard_postgres_array_format():
193193 }
194194
195195 #[Test]
196- public function transform_array_item_for_php_returns_null_for_null (): void
196+ public function can_transform_array_item_for_php_returning_null_for_null (): void
197197 {
198198 $ this ->assertNull ($ this ->fixture ->transformArrayItemForPHP (null ));
199199 }
200200
201201 #[Test]
202202 #[DataProvider('provideInvalidTypes ' )]
203- public function transform_array_item_for_php_throws_for_invalid_type (mixed $ value ): void
203+ public function can_transform_array_item_for_php_throwing_for_invalid_type (mixed $ value ): void
204204 {
205205 $ this ->expectException (InvalidPointArrayItemForPHPException::class);
206206 $ this ->fixture ->transformArrayItemForPHP ($ value );
207207 }
208208
209209 #[Test]
210210 #[DataProvider('provideInvalidTypes ' )]
211- public function transform_postgres_array_to_php_array_returns_empty_for_invalid_format (mixed $ value ): void
211+ public function can_transform_postgres_array_to_php_array_returning_empty_for_invalid_format (mixed $ value ): void
212212 {
213213 $ reflectionObject = new \ReflectionObject ($ this ->fixture );
214214 $ reflectionMethod = $ reflectionObject ->getMethod ('transformPostgresArrayToPHPArray ' );
Original file line number Diff line number Diff line change @@ -124,15 +124,15 @@ public static function provideInvalidDatabaseValues(): array
124124 }
125125
126126 #[Test]
127- public function allows_coordinate_with_exactly_6_decimal_places (): void
127+ public function can_allow_coordinate_with_exactly_6_decimal_places (): void
128128 {
129129 $ point = new PointValueObject (1.123456 , 2.654321 );
130130 $ this ->assertSame (1.123456 , $ point ->getX ());
131131 $ this ->assertSame (2.654321 , $ point ->getY ());
132132 }
133133
134134 #[Test]
135- public function throws_for_coordinate_with_more_than_6_decimal_places (): void
135+ public function throws_exception_for_coordinate_with_more_than_6_decimal_places (): void
136136 {
137137 $ this ->expectException (\InvalidArgumentException::class);
138138 new PointValueObject (1.1234567 , 2.0 );
Original file line number Diff line number Diff line change @@ -110,7 +110,7 @@ public static function provideFromStringTestCases(): \Generator
110110 }
111111
112112 #[Test]
113- public function validates_int4_bounds_for_lower (): void
113+ public function can_validate_int4_bounds_for_lower (): void
114114 {
115115 $ this ->expectException (\InvalidArgumentException::class);
116116 $ this ->expectExceptionMessage ('Lower bound -2147483649 is outside INT4 range ' );
@@ -119,7 +119,7 @@ public function validates_int4_bounds_for_lower(): void
119119 }
120120
121121 #[Test]
122- public function validates_int4_bounds_for_upper (): void
122+ public function can_validate_int4_bounds_for_upper (): void
123123 {
124124 $ this ->expectException (\InvalidArgumentException::class);
125125 $ this ->expectExceptionMessage ('Upper bound 2147483648 is outside INT4 range ' );
@@ -128,7 +128,7 @@ public function validates_int4_bounds_for_upper(): void
128128 }
129129
130130 #[Test]
131- public function allows_max_int4_values (): void
131+ public function can_allow_max_int4_values (): void
132132 {
133133 $ int4Range = new Int4Range (-2147483648 , 2147483647 );
134134
Original file line number Diff line number Diff line change @@ -219,7 +219,7 @@ public static function provideFromStringTestCases(): \Generator
219219 }
220220
221221 #[Test]
222- public function handles_microseconds_correctly (): void
222+ public function can_handle_microseconds_correctly (): void
223223 {
224224 $ start = new \DateTimeImmutable ('2023-01-01 10:00:00.123456 ' );
225225 $ end = new \DateTimeImmutable ('2023-01-01 18:00:00.654321 ' );
Original file line number Diff line number Diff line change @@ -159,7 +159,7 @@ public static function provideFromStringTestCases(): \Generator
159159 }
160160
161161 #[Test]
162- public function handles_different_timezones (): void
162+ public function can_handle_different_timezones (): void
163163 {
164164 $ start = new \DateTimeImmutable ('2023-01-01 10:00:00+02:00 ' );
165165 $ end = new \DateTimeImmutable ('2023-01-01 18:00:00-05:00 ' );
@@ -169,7 +169,7 @@ public function handles_different_timezones(): void
169169 }
170170
171171 #[Test]
172- public function handles_microseconds_with_timezone (): void
172+ public function can_handle_microseconds_with_timezone (): void
173173 {
174174 $ start = new \DateTimeImmutable ('2023-01-01 10:00:00.123456+00:00 ' );
175175 $ end = new \DateTimeImmutable ('2023-01-01 18:00:00.654321+00:00 ' );
@@ -233,7 +233,7 @@ public function throws_exception_for_invalid_timestamp_string_via_from_string():
233233 }
234234
235235 #[Test]
236- public function preserves_timezone_information (): void
236+ public function can_preserve_timezone_information (): void
237237 {
238238 $ timestampWithTz = new \DateTimeImmutable ('2023-01-01 10:00:00+02:00 ' );
239239 $ tstzRange = new TstzRange ($ timestampWithTz , null );
You can’t perform that action at this time.
0 commit comments