Skip to content

Commit 3aed09a

Browse files
committed
EndToEnd Tests: fix the code to allow for new exit codes
As of PHPCS 4.0, the exit codes have changed. This commit fixes the tests to expect the new exit codes.
1 parent d4586bf commit 3aed09a

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tests/EndToEnd/phpcbf_test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ function test_phpcbf_is_working_in_parallel() {
2020

2121
function test_phpcbf_returns_error_on_issues() {
2222
OUTPUT="$( { bin/phpcbf --no-colors --no-cache --suffix=.fixed --standard=tests/EndToEnd/Fixtures/endtoend.xml.dist tests/EndToEnd/Fixtures/ClassWithStyleError.inc; } 2>&1 )"
23-
assert_exit_code 1
23+
assert_successful_code
2424

2525
assert_contains "F 1 / 1 (100%)" "$OUTPUT"
2626
assert_contains "A TOTAL OF 1 ERROR WERE FIXED IN 1 FILE" "$OUTPUT"

tests/EndToEnd/phpcs_test.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ function test_phpcs_is_working_in_parallel() {
1010

1111
function test_phpcs_returns_error_on_issues() {
1212
OUTPUT="$( { bin/phpcs --no-colors --no-cache --standard=tests/EndToEnd/Fixtures/endtoend.xml.dist tests/EndToEnd/Fixtures/ClassWithStyleError.inc; } 2>&1 )"
13-
assert_exit_code 2
13+
assert_exit_code 1
1414

1515
assert_contains "E 1 / 1 (100%)" "$OUTPUT"
1616
assert_contains "FOUND 1 ERROR AFFECTING 1 LINE" "$OUTPUT"

0 commit comments

Comments
 (0)