feat: adds --flaky cli option

This commit is contained in:
nuno maduro
2026-04-10 20:03:50 +01:00
parent f528bd8427
commit 3855249ce9
7 changed files with 42 additions and 11 deletions

View File

@ -28,6 +28,7 @@
--pull-request Output to standard output tests with the given pull request number (alias for --pr)
--retry Run non-passing tests first and stop execution upon first error or failure
--dirty ...... Only run tests that have uncommitted changes according to Git
--flaky .................... Output to standard output tests marked as flaky
--all .................... Ignore test selection from XML configuration file
--list-suites ................................... List available test suites
--testsuite [name] ......... Only run tests from the specified test suite(s)

View File

@ -1862,9 +1862,9 @@
PASS Tests\Visual\Help
✓ visual snapshot of help command output
WARN Tests\Visual\JUnit
PASS Tests\Visual\JUnit
✓ junit output
- junit with parallel → Not working yet
junit with parallel
PASS Tests\Visual\Parallel
✓ parallel
@ -1903,4 +1903,4 @@
✓ pass with dataset with ('my-datas-set-value')
✓ within describe → pass with dataset with ('my-datas-set-value')
Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 40 todos, 36 skipped, 1295 passed (2964 assertions)
Tests: 2 deprecated, 4 warnings, 5 incomplete, 2 notices, 40 todos, 35 skipped, 1296 passed (2977 assertions)

View File

@ -60,20 +60,17 @@ test('junit with parallel', function () use ($normalizedPath, $run) {
expect($result['testsuite']['@attributes'])
->name->toBe('Tests\tests\SuccessOnly')
->file->toBe($normalizedPath('tests/.tests/SuccessOnly.php'))
->tests->toBe('2')
->assertions->toBe('2')
->tests->toBe('1')
->assertions->toBe('1')
->errors->toBe('0')
->failures->toBe('0')
->skipped->toBe('0');
expect($result['testsuite']['testcase'])
->toHaveCount(2);
expect($result['testsuite']['testcase'][0]['@attributes'])
expect($result['testsuite']['testcase']['@attributes'])
->name->toBe('it can pass with comparison')
->file->toBe($normalizedPath('tests/.tests/SuccessOnly.php::it can pass with comparison'))
->class->toBe('Tests\tests\SuccessOnly')
->classname->toBe('Tests.tests.SuccessOnly')
->assertions->toBe('1')
->time->toStartWith('0.0');
})->skip('Not working yet');
});