Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(106)

Unified Diff: tests/isolate_smoke_test.py

Issue 51383003: Report all swarming and isolate fatal errors in a consistent way. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/swarm_client
Patch Set: make isolate_smoke_test less strict regarding exact contents of stderr Created 7 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « swarming.py ('k') | tests/run_isolated_smoke_test.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/isolate_smoke_test.py
diff --git a/tests/isolate_smoke_test.py b/tests/isolate_smoke_test.py
index d2e66e87f751f916ac72bdfc5ca00b5a9cd44dc9..9adab0637ee597b29054dfa07d1f65c225c92fcc 100755
--- a/tests/isolate_smoke_test.py
+++ b/tests/isolate_smoke_test.py
@@ -364,11 +364,10 @@ class IsolateModeBase(IsolateBase):
self._expect_no_result()
root = file_path.get_native_path_case(unicode(ROOT_DIR))
expected = (
- '\n'
- 'Error: Input directory %s must have a trailing slash\n' %
+ 'Input directory %s must have a trailing slash' %
os.path.join(root, 'tests', 'isolate', 'files1')
)
- self.assertEqual(expected, out)
+ self.assertIn(expected, out)
def _test_non_existent(self, mode):
try:
@@ -381,11 +380,10 @@ class IsolateModeBase(IsolateBase):
self._expect_no_result()
root = file_path.get_native_path_case(unicode(ROOT_DIR))
expected = (
- '\n'
- 'Error: Input file %s doesn\'t exist\n' %
+ 'Input file %s doesn\'t exist' %
os.path.join(root, 'tests', 'isolate', 'A_file_that_do_not_exist')
)
- self.assertEqual(expected, out)
+ self.assertIn(expected, out)
def _test_all_items_invalid(self, mode):
out = self._execute(mode, 'all_items_invalid.isolate',
@@ -842,9 +840,9 @@ class Isolate_trace_read_merge(IsolateModeBase):
err = e.stderr
self._expect_no_tree()
self._expect_no_result()
- expected = '\nError: No command to run.\n'
+ expected = 'No command to run.'
self.assertEqual('', out)
- self.assertEqual(expected, err)
+ self.assertIn(expected, err)
# TODO(csharp): Disabled until crbug.com/150823 is fixed.
def do_not_test_touch_only(self):
« no previous file with comments | « swarming.py ('k') | tests/run_isolated_smoke_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698