Merge pull request #15852 from MikeMcQuaid/tests_fail_fast
dev-cmd/tests: add `--fail-fast`.
This commit is contained in:
commit
f70a49be2f
@ -24,6 +24,8 @@ module Homebrew
|
|||||||
description: "Enable debugging using byebug."
|
description: "Enable debugging using byebug."
|
||||||
switch "--changed",
|
switch "--changed",
|
||||||
description: "Only runs tests on files that were changed from the master branch."
|
description: "Only runs tests on files that were changed from the master branch."
|
||||||
|
switch "--fail-fast",
|
||||||
|
description: "Exit early on the first failing test."
|
||||||
flag "--only=",
|
flag "--only=",
|
||||||
description: "Run only <test_script>`_spec.rb`. Appending `:`<line_number> will start at a " \
|
description: "Run only <test_script>`_spec.rb`. Appending `:`<line_number> will start at a " \
|
||||||
"specific line."
|
"specific line."
|
||||||
@ -153,6 +155,7 @@ module Homebrew
|
|||||||
--color
|
--color
|
||||||
--require spec_helper
|
--require spec_helper
|
||||||
]
|
]
|
||||||
|
bundle_args << "--fail-fast" if args.fail_fast?
|
||||||
|
|
||||||
# TODO: Refactor and move to extend/os
|
# TODO: Refactor and move to extend/os
|
||||||
# rubocop:disable Homebrew/MoveToExtendOS
|
# rubocop:disable Homebrew/MoveToExtendOS
|
||||||
|
@ -2210,6 +2210,7 @@ _brew_tests() {
|
|||||||
--changed
|
--changed
|
||||||
--coverage
|
--coverage
|
||||||
--debug
|
--debug
|
||||||
|
--fail-fast
|
||||||
--generic
|
--generic
|
||||||
--help
|
--help
|
||||||
--online
|
--online
|
||||||
|
@ -1470,6 +1470,7 @@ __fish_brew_complete_arg 'tests' -l byebug -d 'Enable debugging using byebug'
|
|||||||
__fish_brew_complete_arg 'tests' -l changed -d 'Only runs tests on files that were changed from the master branch'
|
__fish_brew_complete_arg 'tests' -l changed -d 'Only runs tests on files that were changed from the master branch'
|
||||||
__fish_brew_complete_arg 'tests' -l coverage -d 'Generate code coverage reports'
|
__fish_brew_complete_arg 'tests' -l coverage -d 'Generate code coverage reports'
|
||||||
__fish_brew_complete_arg 'tests' -l debug -d 'Display any debugging information'
|
__fish_brew_complete_arg 'tests' -l debug -d 'Display any debugging information'
|
||||||
|
__fish_brew_complete_arg 'tests' -l fail-fast -d 'Exit early on the first failing test'
|
||||||
__fish_brew_complete_arg 'tests' -l generic -d 'Run only OS-agnostic tests'
|
__fish_brew_complete_arg 'tests' -l generic -d 'Run only OS-agnostic tests'
|
||||||
__fish_brew_complete_arg 'tests' -l help -d 'Show this message'
|
__fish_brew_complete_arg 'tests' -l help -d 'Show this message'
|
||||||
__fish_brew_complete_arg 'tests' -l online -d 'Include tests that use the GitHub API and tests that use any of the taps for official external commands'
|
__fish_brew_complete_arg 'tests' -l online -d 'Include tests that use the GitHub API and tests that use any of the taps for official external commands'
|
||||||
|
@ -1815,6 +1815,7 @@ _brew_tests() {
|
|||||||
'(--only)--changed[Only runs tests on files that were changed from the master branch]' \
|
'(--only)--changed[Only runs tests on files that were changed from the master branch]' \
|
||||||
'--coverage[Generate code coverage reports]' \
|
'--coverage[Generate code coverage reports]' \
|
||||||
'--debug[Display any debugging information]' \
|
'--debug[Display any debugging information]' \
|
||||||
|
'--fail-fast[Exit early on the first failing test]' \
|
||||||
'--generic[Run only OS-agnostic tests]' \
|
'--generic[Run only OS-agnostic tests]' \
|
||||||
'--help[Show this message]' \
|
'--help[Show this message]' \
|
||||||
'--online[Include tests that use the GitHub API and tests that use any of the taps for official external commands]' \
|
'--online[Include tests that use the GitHub API and tests that use any of the taps for official external commands]' \
|
||||||
|
@ -1579,6 +1579,8 @@ Run Homebrew's unit and integration tests.
|
|||||||
Enable debugging using byebug.
|
Enable debugging using byebug.
|
||||||
* `--changed`:
|
* `--changed`:
|
||||||
Only runs tests on files that were changed from the master branch.
|
Only runs tests on files that were changed from the master branch.
|
||||||
|
* `--fail-fast`:
|
||||||
|
Exit early on the first failing test.
|
||||||
* `--only`:
|
* `--only`:
|
||||||
Run only *`test_script`*`_spec.rb`. Appending `:`*`line_number`* will start at a specific line.
|
Run only *`test_script`*`_spec.rb`. Appending `:`*`line_number`* will start at a specific line.
|
||||||
* `--seed`:
|
* `--seed`:
|
||||||
|
@ -2274,6 +2274,10 @@ Enable debugging using byebug\.
|
|||||||
Only runs tests on files that were changed from the master branch\.
|
Only runs tests on files that were changed from the master branch\.
|
||||||
.
|
.
|
||||||
.TP
|
.TP
|
||||||
|
\fB\-\-fail\-fast\fR
|
||||||
|
Exit early on the first failing test\.
|
||||||
|
.
|
||||||
|
.TP
|
||||||
\fB\-\-only\fR
|
\fB\-\-only\fR
|
||||||
Run only \fItest_script\fR\fB_spec\.rb\fR\. Appending \fB:\fR\fIline_number\fR will start at a specific line\.
|
Run only \fItest_script\fR\fB_spec\.rb\fR\. Appending \fB:\fR\fIline_number\fR will start at a specific line\.
|
||||||
.
|
.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user