mirror of
https://we.phorge.it/source/arcanist.git
synced 2024-11-10 08:52:39 +01:00
Don't ask for confirmation with unsound unit tests
Test Plan: $ arc diff # with unsound tests $ arc diff --ignore-unsound-tests # with unsound tests Reviewers: epriestley, aran Reviewed By: epriestley CC: aran, Korvin Maniphest Tasks: T1515 Differential Revision: https://secure.phabricator.com/D2985
This commit is contained in:
parent
014521362f
commit
30bc4ca6e9
1 changed files with 14 additions and 5 deletions
|
@ -342,6 +342,9 @@ EOTEXT
|
|||
'skip-binaries' => array(
|
||||
'help' => 'Do not upload binaries (like images).',
|
||||
),
|
||||
'ignore-unsound-tests' => array(
|
||||
'help' => 'Ignore unsound test failures without prompting.',
|
||||
),
|
||||
'base' => array(
|
||||
'param' => 'rules',
|
||||
'help' => 'Additional rules for determining base revision.',
|
||||
|
@ -1296,12 +1299,18 @@ EOTEXT
|
|||
"<bg:green>** UNIT OKAY **</bg> No unit test failures.\n");
|
||||
break;
|
||||
case ArcanistUnitWorkflow::RESULT_UNSOUND:
|
||||
if ($this->getArgument('ignore-unsound-tests')) {
|
||||
echo phutil_console_format(
|
||||
"<bg:yellow>** UNIT UNSOUND **</bg> Unit testing raised errors, ".
|
||||
"but all failing tests are unsound.\n");
|
||||
} else {
|
||||
$continue = phutil_console_confirm(
|
||||
"Unit test results included failures, but all failing tests ".
|
||||
"are known to be unsound. Ignore unsound test failures?");
|
||||
if (!$continue) {
|
||||
throw new ArcanistUserAbortException();
|
||||
}
|
||||
}
|
||||
break;
|
||||
case ArcanistUnitWorkflow::RESULT_FAIL:
|
||||
$this->console->writeOut(
|
||||
|
|
Loading…
Reference in a new issue