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

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

Issue 2188733003: Implement functionality to cc relevant owners. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: implement functionality to cc relevant owners Created 4 years, 4 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
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 unittest 5 import unittest
6 6
7 from webkitpy.w3c.deps_updater import DepsUpdater 7 from webkitpy.w3c.deps_updater import DepsUpdater
8 from webkitpy.common.host_mock import MockHost 8 from webkitpy.common.host_mock import MockHost
9 from webkitpy.common.system.filesystem_mock import MockFileSystem 9 from webkitpy.common.system.filesystem_mock import MockFileSystem
10 10
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 61
62 def test_is_manual_test_with_corresponding_automation_file(self): 62 def test_is_manual_test_with_corresponding_automation_file(self):
63 updater = DepsUpdater(MockHost()) 63 updater = DepsUpdater(MockHost())
64 imported_dir = '/mock-checkout/third_party/WebKit/LayoutTests/imported/' 64 imported_dir = '/mock-checkout/third_party/WebKit/LayoutTests/imported/'
65 fs = MockFileSystem(files={ 65 fs = MockFileSystem(files={
66 imported_dir + 'wpt_automation/a/x-manual-input.js': '', 66 imported_dir + 'wpt_automation/a/x-manual-input.js': '',
67 imported_dir + 'wpt_automation/a/y-manual-automation.js': '', 67 imported_dir + 'wpt_automation/a/y-manual-automation.js': '',
68 }) 68 })
69 self.assertTrue(updater.is_manual_test(fs, imported_dir + 'wpt/a', 'x-ma nual.html')) 69 self.assertTrue(updater.is_manual_test(fs, imported_dir + 'wpt/a', 'x-ma nual.html'))
70 self.assertFalse(updater.is_manual_test(fs, imported_dir + 'wpt/a', 'y-m anual.html')) 70 self.assertFalse(updater.is_manual_test(fs, imported_dir + 'wpt/a', 'y-m anual.html'))
71
72 def test_parse_imported_changes(self):
73 updater = DepsUpdater(MockHost())
74 owners = {'foo/bar': 'me@gmail.com', 'foo/baz': 'you@gmail.com', 'foo/ba t': 'noone@gmail.com'}
75 results = 'foo/bar/file.html\nfoo/bar/otherfile.html\nfoo/baz/files.html '
76 updater.parse_imported_test_changes(results, owners)
77 self.assertEqual(updater.email_list, ['--cc=me@gmail.com', '--cc=you@gma il.com'])
qyearsley 2016/07/27 21:38:57 Could you also add a test method for parse_directo
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698