File tree Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -391,7 +391,7 @@ To run the tests specific to the use of `PHP_CODESNIFFER_CBF === true`:
391391
392392### Writing End-to-End Tests
393393
394- Bash-based end-to-end tests can be written using the [Bashunit](https://bashunit.typeddevs.com/) test tooling.
394+ Bash-based end-to-end tests can be written using the [Bashunit](https://bashunit.typeddevs.com/) test tooling using version 0.26.0 or higher .
395395
396396To install bashunit, follow the [installation guide](https://bashunit.typeddevs.com/installation).
397397
Original file line number Diff line number Diff line change @@ -6,9 +6,8 @@ function tear_down() {
66
77function test_phpcs_out_of_memory_error_handling() {
88 OUTPUT=" $( bin/phpcs -d memory_limit=4M --standard=tests/EndToEnd/Fixtures/endtoend.xml.dist tests/EndToEnd/Fixtures/) "
9- # Exit code can't currently be tested as it looks like it may be 255 or 139 depending on the PHP version.
10- # Related feature request upstream: https://github.com/TypedDevs/bashunit/issues/505
11- # assert_exit_code 255
9+ # Exit code may be 255 or 139 depending on the PHP version, but the exact code is not our concern, just that it's non-zero.
10+ assert_unsuccessful_code
1211
1312 assert_contains " The PHP_CodeSniffer \" phpcs\" command ran out of memory." " $OUTPUT "
1413 assert_contains " Either raise the \" memory_limit\" of PHP in the php.ini file or raise the memory limit at runtime" " $OUTPUT "
@@ -17,9 +16,8 @@ function test_phpcs_out_of_memory_error_handling() {
1716
1817function test_phpcbf_out_of_memory_error_handling() {
1918 OUTPUT=" $( bin/phpcbf -d memory_limit=4M --standard=tests/EndToEnd/Fixtures/endtoend.xml.dist tests/EndToEnd/Fixtures/ --suffix=.fixed) "
20- # Exit code can't currently be tested as it looks like it may be 255 or 139 depending on the PHP version.
21- # Related feature request upstream: https://github.com/TypedDevs/bashunit/issues/505
22- # assert_exit_code 255
19+ # Exit code may be 255 or 139 depending on the PHP version, but the exact code is not our concern, just that it's non-zero.
20+ assert_unsuccessful_code
2321
2422 assert_contains " The PHP_CodeSniffer \" phpcbf\" command ran out of memory." " $OUTPUT "
2523 assert_contains " Either raise the \" memory_limit\" of PHP in the php.ini file or raise the memory limit at runtime" " $OUTPUT "
You can’t perform that action at this time.
0 commit comments