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

Unified Diff: third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines_unittest.py

Issue 2397573002: Don't track SCM changes in rebaseline commands. (Closed)
Patch Set: Update message and docstring for has_working_directory_changes Created 4 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
Index: third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines_unittest.py
diff --git a/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines_unittest.py b/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines_unittest.py
index 715e6a68b2a69f5cfcc020416a45ef9b5a22defb..b1a443e2af771968a754eeb1c7705d288629bd3f 100644
--- a/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines_unittest.py
+++ b/third_party/WebKit/Tools/Scripts/webkitpy/tool/commands/optimize_baselines_unittest.py
@@ -19,41 +19,6 @@ class TestOptimizeBaselines(BaseTestCase):
def setUp(self):
super(TestOptimizeBaselines, self).setUp()
- def test_modify_scm(self):
- test_port = self.tool.port_factory.get('test')
- self._write_test_file(test_port, 'another/test.html', "Dummy test contents")
- self._write_test_file(test_port, 'platform/test-mac-mac10.10/another/test-expected.txt', "result A")
- self._write_test_file(test_port, 'another/test-expected.txt', "result A")
-
- OutputCapture().assert_outputs(self, self.command.execute, args=[
- optparse.Values({'suffixes': 'txt', 'no_modify_scm': False, 'platform': 'test-mac-mac10.10'}),
- ['another/test.html'],
- self.tool,
- ], expected_stdout='{"add": [], "remove-lines": [], "delete": []}\n')
-
- self.assertFalse(self.tool.filesystem.exists(self.tool.filesystem.join(
- test_port.layout_tests_dir(), 'platform/test-mac-mac10.10/another/test-expected.txt')))
- self.assertTrue(self.tool.filesystem.exists(self.tool.filesystem.join(
- test_port.layout_tests_dir(), 'another/test-expected.txt')))
-
- def test_no_modify_scm(self):
- test_port = self.tool.port_factory.get('test')
- self._write_test_file(test_port, 'another/test.html', "Dummy test contents")
- self._write_test_file(test_port, 'platform/test-mac-mac10.10/another/test-expected.txt', "result A")
- self._write_test_file(test_port, 'another/test-expected.txt', "result A")
-
- OutputCapture().assert_outputs(self, self.command.execute, args=[
- optparse.Values({'suffixes': 'txt', 'no_modify_scm': True, 'platform': 'test-mac-mac10.10'}),
- ['another/test.html'],
- self.tool,
- ], expected_stdout=('{"add": [], "remove-lines": [], '
- '"delete": ["/test.checkout/LayoutTests/platform/test-mac-mac10.10/another/test-expected.txt"]}\n'))
-
- self.assertFalse(self.tool.filesystem.exists(self.tool.filesystem.join(
- test_port.layout_tests_dir(), 'platform/mac/another/test-expected.txt')))
- self.assertTrue(self.tool.filesystem.exists(self.tool.filesystem.join(
- test_port.layout_tests_dir(), 'another/test-expected.txt')))
-
def test_optimize_all_suffixes_by_default(self):
test_port = self.tool.port_factory.get('test')
self._write_test_file(test_port, 'another/test.html', "Dummy test contents")
@@ -70,13 +35,8 @@ class TestOptimizeBaselines(BaseTestCase):
['another/test.html'],
self.tool)
finally:
- out, _, _ = oc.restore_output()
+ oc.restore_output()
- self.assertEquals(
- out,
- '{"add": [], "remove-lines": [], '
- '"delete": ["/test.checkout/LayoutTests/platform/test-mac-mac10.10/another/test-expected.txt", '
- '"/test.checkout/LayoutTests/platform/test-mac-mac10.10/another/test-expected.png"]}\n')
self.assertFalse(
self.tool.filesystem.exists(self.tool.filesystem.join(
test_port.layout_tests_dir(), 'platform/mac/another/test-expected.txt')))

Powered by Google App Engine
This is Rietveld 408576698