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

Side by Side Diff: third_party/WebKit/Tools/Scripts/webkitpy/w3c/test_importer_unittest.py

Issue 2679173005: Rename Host.scm -> Host.git. (Closed)
Patch Set: Created 3 years, 10 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Tools/Scripts/webkitpy/w3c/test_importer.py ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright 2016 The Chromium Authors. All rights reserved. 1 # Copyright 2016 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import collections 5 import collections
6 6
7 from webkitpy.common.checkout.git_mock import MockGit 7 from webkitpy.common.checkout.git_mock import MockGit
8 from webkitpy.common.host_mock import MockHost 8 from webkitpy.common.host_mock import MockHost
9 from webkitpy.common.system.executive_mock import MockExecutive 9 from webkitpy.common.system.executive_mock import MockExecutive
10 from webkitpy.common.system.log_testing import LoggingTestCase 10 from webkitpy.common.system.log_testing import LoggingTestCase
(...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 ]) 144 ])
145 145
146 def test_get_directory_owners(self): 146 def test_get_directory_owners(self):
147 host = MockHost() 147 host = MockHost()
148 host.filesystem.write_text_file( 148 host.filesystem.write_text_file(
149 '/mock-checkout/third_party/WebKit/LayoutTests/W3CImportExpectations ', 149 '/mock-checkout/third_party/WebKit/LayoutTests/W3CImportExpectations ',
150 '## Owners: someone@chromium.org\n' 150 '## Owners: someone@chromium.org\n'
151 '# external/wpt/foo [ Pass ]\n') 151 '# external/wpt/foo [ Pass ]\n')
152 git = MockGit() 152 git = MockGit()
153 git.changed_files = lambda: ['third_party/WebKit/LayoutTests/external/wp t/foo/x.html'] 153 git.changed_files = lambda: ['third_party/WebKit/LayoutTests/external/wp t/foo/x.html']
154 host.scm = lambda: git 154 host.git = lambda: git
155 importer = TestImporter(host) 155 importer = TestImporter(host)
156 self.assertEqual(importer.get_directory_owners(), {'someone@chromium.org ': 'external/wpt/foo'}) 156 self.assertEqual(importer.get_directory_owners(), {'someone@chromium.org ': 'external/wpt/foo'})
157 157
158 def test_get_directory_owners_no_changed_files(self): 158 def test_get_directory_owners_no_changed_files(self):
159 host = MockHost() 159 host = MockHost()
160 host.filesystem.write_text_file( 160 host.filesystem.write_text_file(
161 '/mock-checkout/third_party/WebKit/LayoutTests/W3CImportExpectations ', 161 '/mock-checkout/third_party/WebKit/LayoutTests/W3CImportExpectations ',
162 '## Owners: someone@chromium.org\n' 162 '## Owners: someone@chromium.org\n'
163 '# external/wpt/foo [ Pass ]\n') 163 '# external/wpt/foo [ Pass ]\n')
164 importer = TestImporter(host) 164 importer = TestImporter(host)
165 self.assertEqual(importer.get_directory_owners(), {}) 165 self.assertEqual(importer.get_directory_owners(), {})
OLDNEW
« no previous file with comments | « third_party/WebKit/Tools/Scripts/webkitpy/w3c/test_importer.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698