Skip to content

Commit

Permalink
fix: color result output incorrect in some cases
Browse files Browse the repository at this point in the history
  • Loading branch information
gerardroche committed Nov 12, 2023
1 parent bd1087f commit bde8100
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

All notable changes are documented in this file using the [Keep a CHANGELOG](http://keepachangelog.com/) principles.

## 3.18.2 - Unreleased

### Fixed

- Fix result output footer edge-cases

## 3.18.1 - 2023-08-16

### Deprecated
Expand Down
2 changes: 1 addition & 1 deletion res/text-ui-result.sublime-syntax
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ contexts:
- match: '^{{cc}}OK, but incomplete, skipped, or risky tests\!{{cc}}$'
scope: region.orangish phpunitkit test.footer.ok-but-incomplete-skipped-or-risky.phpunit-result

- match: '^{{cc}}OK, but there are issues\!{{cc}}$'
- match: '^{{cc}}OK, but (?:there are issues|some tests were skipped)\!{{cc}}$'
scope: region.orangish phpunitkit test.footer.ok-but-incomplete-skipped-or-risky.phpunit-result
push:
- match: '^{{cc}}Tests\: \d+, Assertions\: \d+(?:, (?:Deprecations|Errors|Failures|Warnings|Notices|Skipped|Incomplete|Risky)\: \d+)+\.{{cc}}$'
Expand Down
29 changes: 29 additions & 0 deletions tests/syntax_test-text-ui-result
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,30 @@ FF........................ 26 / 26 (100%)

Time: 385 ms, Memory: 5.50MB

. 1 / 1 (100%)

Time: 00:00.626, Memory: 32.00 MB

.. 2 / 2 (100%)

Time: 00:00.626, Memory: 32.00 MB

S 1 / 1 (100%)

Time: 00:00.626, Memory: 32.00 MB

SS 2 / 2 (100%)

Time: 00:00.626, Memory: 32.00 MB

F 1 / 1 (100%)

Time: 00:00.626, Memory: 32.00 MB

FF 2 / 2 (100%)

Time: 00:00.626, Memory: 32.00 MB

OK (45 tests, 81 assertions)
#<- region.greenish phpunitkit test.footer.ok.phpunit-result
#^^^^^^^^^^^^^^^^^^^^^^^^^^^ region.greenish phpunitkit test.footer.ok.phpunit-result
Expand Down Expand Up @@ -104,6 +128,11 @@ Tests: 81, Assertions: 81, Deprecations: 4.
#<- region.orangish phpunitkit test.footer.ok-but-incomplete-skipped-or-risky.phpunit-result
#^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ region.orangish phpunitkit test.footer.ok-but-incomplete-skipped-or-risky.phpunit-result

OK, but some tests were skipped!
# ^ region.orangish phpunitkit test.footer.ok-but-incomplete-skipped-or-risky.phpunit-result
Tests: 31, Assertions: 41, Skipped: 6.
# ^ region.orangish phpunitkit test.footer.ok-but-incomplete-skipped-or-risky.phpunit-result

FAILURES!
#<- region.redish phpunitkit test.footer.fail.phpunit-result
#^^^^^^^^ region.redish phpunitkit test.footer.fail.phpunit-result
Expand Down

0 comments on commit bde8100

Please sign in to comment.