1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-19 12:00:55 +01:00

Log the update test result error instead of throwing an exception.

Summary:
For some unknown reasons, our test framework fails to update test
results occasionally. Instead of throwing a nasty exception, log
the error message. This will help us to figure out the real reason
behind the error.

Test Plan:
arc lint.

Reviewed By: epriestley
Reviewers: jungejason, epriestley
CC: epriestley, aran
Differential Revision: 463
This commit is contained in:
tuomaspelkonen 2011-06-14 14:01:47 -07:00
parent d33670c416
commit a187b2cedc
2 changed files with 4 additions and 2 deletions

View file

@ -41,7 +41,6 @@ extends ConduitAPIMethod {
return array(
'ERR_BAD_DIFF' => 'Bad diff ID.',
'ERR_NO_RESULTS' => 'Could not find the postponed test',
'ERR_BAD_FILE' => 'No results for given file',
);
}
@ -88,7 +87,9 @@ extends ConduitAPIMethod {
unset($unit_result);
if (!$unit_status) {
throw new ConduitException('ERR_BAD_FILE');
phlog("Could not update test results: {$diff_id} {$file} {$name}".
" {$result} {$message}");
return;
}
$diff_property->setData($unit_results);

View file

@ -13,6 +13,7 @@ phutil_require_module('phabricator', 'applications/differential/constants/unitte
phutil_require_module('phabricator', 'applications/differential/storage/diff');
phutil_require_module('phabricator', 'applications/differential/storage/diffproperty');
phutil_require_module('phutil', 'error');
phutil_require_module('phutil', 'utils');