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

Unified Diff: gm/rebaseline_server/results_test.py

Issue 232103002: rebaseline_server: allow user to specify which builders to process (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: expose to command line Created 6 years, 8 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
Index: gm/rebaseline_server/results_test.py
diff --git a/gm/rebaseline_server/results_test.py b/gm/rebaseline_server/results_test.py
index a2f4073dcf73e02f7b40b0a1df9b0db62c955d87..f22e833fe3a24f452fc9615d3e68ce559b6df341 100755
--- a/gm/rebaseline_server/results_test.py
+++ b/gm/rebaseline_server/results_test.py
@@ -17,6 +17,29 @@ import results
class ResultsTest(base_unittest.TestCase):
+ def test_ignore_builder(self):
+ """Test _ignore_builder()."""
+ results_obj = results.BaseComparisons()
+ self.assertEqual(results_obj._ignore_builder('SomethingTSAN'), True)
+ self.assertEqual(results_obj._ignore_builder('Something-Trybot'), True)
+ self.assertEqual(results_obj._ignore_builder(
+ 'Test-Ubuntu12-ShuttleA-GTX660-x86-Release'), False)
+ results_obj.set_skip_builders_pattern_list(['.*TSAN.*', '.*GTX660.*'])
+ self.assertEqual(results_obj._ignore_builder('SomethingTSAN'), True)
+ self.assertEqual(results_obj._ignore_builder('Something-Trybot'), False)
+ self.assertEqual(results_obj._ignore_builder(
+ 'Test-Ubuntu12-ShuttleA-GTX660-x86-Release'), True)
+ results_obj.set_skip_builders_pattern_list(None)
+ self.assertEqual(results_obj._ignore_builder('SomethingTSAN'), False)
+ self.assertEqual(results_obj._ignore_builder('Something-Trybot'), False)
+ self.assertEqual(results_obj._ignore_builder(
+ 'Test-Ubuntu12-ShuttleA-GTX660-x86-Release'), False)
+ results_obj.set_match_builders_pattern_list(['.*TSAN'])
+ self.assertEqual(results_obj._ignore_builder('SomethingTSAN'), False)
+ self.assertEqual(results_obj._ignore_builder('Something-Trybot'), True)
+ self.assertEqual(results_obj._ignore_builder(
+ 'Test-Ubuntu12-ShuttleA-GTX660-x86-Release'), True)
+
def test_combine_subdicts_typical(self):
"""Test combine_subdicts() with no merge conflicts. """
input_dict = {

Powered by Google App Engine
This is Rietveld 408576698