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

Unified Diff: scripts/slave/recipe_modules/auto_bisect/bisector_test.py

Issue 1782263002: Don't check improvement direction for return_code bisects. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/build.git@master
Patch Set: Created 4 years, 9 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 | « scripts/slave/recipe_modules/auto_bisect/bisector.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scripts/slave/recipe_modules/auto_bisect/bisector_test.py
diff --git a/scripts/slave/recipe_modules/auto_bisect/bisector_test.py b/scripts/slave/recipe_modules/auto_bisect/bisector_test.py
index 70c357395559076d0ed951d4c9ae81c3411dbe83..ea7c53230a91b6761f44e83382d0f3cc2b2cb2ce 100755
--- a/scripts/slave/recipe_modules/auto_bisect/bisector_test.py
+++ b/scripts/slave/recipe_modules/auto_bisect/bisector_test.py
@@ -112,7 +112,7 @@ class BisectorTest(unittest.TestCase): # pragma: no cover
self.assertNotIn('direction of improvement', ''.join(bisector.warnings))
def test_improvement_direction_return_code(self):
- # Good revision is bad or bad revision is good, should fail.
+ # The improvement direction check doesn't apply for return code bisects.
bisect_config = copy.deepcopy(self.bisect_config)
bisect_config['test_type'] = 'return_code'
bisector = auto_bisect.bisector.Bisector(self.dummy_api, bisect_config,
@@ -120,8 +120,7 @@ class BisectorTest(unittest.TestCase): # pragma: no cover
bisector.good_rev.mean_value = 1
bisector.bad_rev.mean_value = 0
self.assertTrue(bisector.is_return_code_mode())
- self.assertFalse(bisector.check_improvement_direction())
- self.assertIn('return code', ''.join(bisector.warnings))
+ self.assertTrue(bisector.check_improvement_direction())
@mock.patch.object(auto_bisect.bisector.Bisector, 'significantly_different',
mock.MagicMock(return_value=True))
« no previous file with comments | « scripts/slave/recipe_modules/auto_bisect/bisector.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698