Title: [136875] trunk/Tools
Revision
136875
Author
[email protected]
Date
2012-12-06 13:09:58 -0800 (Thu, 06 Dec 2012)

Log Message

Allow for CCing a secondary email address from watchlists
https://bugs.webkit.org/show_bug.cgi?id=104286

Reviewed by Dirk Pranke.

Change my watchlist CC address so I can filter these separately from
when people explicitly CC me and update the watchlist parser to allow that.

* Scripts/webkitpy/common/config/committers.py:
* Scripts/webkitpy/common/config/watchlist:
* Scripts/webkitpy/common/watchlist/watchlistparser.py:
(WatchListParser._validate):
* Scripts/webkitpy/common/watchlist/watchlistparser_unittest.py:
(WatchListParserTest.test_cc_rule_with_invalid_email):
(WatchListParserTest.test_cc_rule_with_secondary_email):

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (136874 => 136875)


--- trunk/Tools/ChangeLog	2012-12-06 20:40:24 UTC (rev 136874)
+++ trunk/Tools/ChangeLog	2012-12-06 21:09:58 UTC (rev 136875)
@@ -1,3 +1,21 @@
+2012-12-06  Ojan Vafai  <[email protected]>
+
+        Allow for CCing a secondary email address from watchlists
+        https://bugs.webkit.org/show_bug.cgi?id=104286
+
+        Reviewed by Dirk Pranke.
+
+        Change my watchlist CC address so I can filter these separately from
+        when people explicitly CC me and update the watchlist parser to allow that.
+
+        * Scripts/webkitpy/common/config/committers.py:
+        * Scripts/webkitpy/common/config/watchlist:
+        * Scripts/webkitpy/common/watchlist/watchlistparser.py:
+        (WatchListParser._validate):
+        * Scripts/webkitpy/common/watchlist/watchlistparser_unittest.py:
+        (WatchListParserTest.test_cc_rule_with_invalid_email):
+        (WatchListParserTest.test_cc_rule_with_secondary_email):
+
 2012-12-06  Max Vujovic  <[email protected]>
 
         Unreviewed. Add myself to committers.py.

Modified: trunk/Tools/Scripts/webkitpy/common/config/committers.py (136874 => 136875)


--- trunk/Tools/Scripts/webkitpy/common/config/committers.py	2012-12-06 20:40:24 UTC (rev 136874)
+++ trunk/Tools/Scripts/webkitpy/common/config/committers.py	2012-12-06 21:09:58 UTC (rev 136875)
@@ -535,7 +535,7 @@
     Reviewer("Nate Chapin", "[email protected]", ["japhet", "natechapin"]),
     Reviewer("Nikolas Zimmermann", ["[email protected]", "[email protected]", "[email protected]", "[email protected]"], "wildfox"),
     Reviewer("Noam Rosenthal", ["[email protected]", "[email protected]"], "noamr"),
-    Reviewer("Ojan Vafai", "[email protected]", "ojan"),
+    Reviewer("Ojan Vafai", ["[email protected]", "[email protected]"], "ojan"),
     Reviewer("Oliver Hunt", "[email protected]", "olliej"),
     Reviewer("Pavel Feldman", ["[email protected]", "[email protected]"], "pfeldman"),
     Reviewer("Philippe Normand", ["[email protected]", "[email protected]", "[email protected]"], ["philn-tp", "pnormand"]),

Modified: trunk/Tools/Scripts/webkitpy/common/config/watchlist (136874 => 136875)


--- trunk/Tools/Scripts/webkitpy/common/config/watchlist	2012-12-06 20:40:24 UTC (rev 136874)
+++ trunk/Tools/Scripts/webkitpy/common/config/watchlist	2012-12-06 21:09:58 UTC (rev 136875)
@@ -309,11 +309,11 @@
         "Cairo": [ "[email protected]" ],
         "CMake": [ "[email protected]", "[email protected]" ],
         "CoordinatedGraphics" : [ "[email protected]", "[email protected]" ],
-        "CSS": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]"],
+        "CSS": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]"],
         "ChromiumGraphics": [ "[email protected]", "[email protected]" ],
         "ChromiumPublicApi": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]", "[email protected]" ],
         "ChromiumTestRunner": [ "[email protected]" ],
-        "DOM": [ "[email protected]" ],
+        "DOM": [ "[email protected]" ],
         "DOMAttributes": [ "[email protected]", ],
         "EFL": [ "[email protected]", "[email protected]" ],
         "EFLWebKit2PlatformSpecific": [ "[email protected]", "[email protected]" ],
@@ -325,7 +325,7 @@
         "GStreamerGraphics": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]" ],
         "GtkWebKit2PublicAPI": [ "[email protected]", "[email protected]", "[email protected]" ],
         "Harfbuzz": [ "[email protected]" ],
-        "HTML": [ "[email protected]" ],
+        "HTML": [ "[email protected]" ],
         "Loader": [ "[email protected]" ],
         "MathML": [ "[email protected]" ],
         "Media": [ "[email protected]", "[email protected]" ],
@@ -337,7 +337,7 @@
         "QtGraphics" : [ "[email protected]" ],
         "QtWebKit2PlatformSpecific": [ "[email protected]", "[email protected]", "[email protected]" ],
         "QtWebKit2PublicAPI": [ "[email protected]", "[email protected]", "[email protected]" ],
-        "Rendering": [ "[email protected]", "[email protected]" ],
+        "Rendering": [ "[email protected]", "[email protected]" ],
         "SVG": ["[email protected]", "[email protected]", "[email protected]", "[email protected]" ],
         "SVNScripts": [ "[email protected]" ],
         "ScrollingCoordinator": [ "[email protected]", "[email protected]", "[email protected]" ],
@@ -346,19 +346,19 @@
         "Selectors": [ "[email protected]" ],
         "SoupNetwork": [ "[email protected]", "[email protected]", "[email protected]", "[email protected]" ],
         "StyleChecker": [ "[email protected]", ],
-        "TestFailures": [ "[email protected]", "[email protected]", "[email protected]" ],
+        "TestFailures": [ "[email protected]", "[email protected]", "[email protected]" ],
         "TextureMapper" : [ "[email protected]" ],
         "ThreadingFiles|ThreadingUsage": [ "[email protected]", ],
         "TouchAdjustment" : [ "[email protected]" ],
         "V8Bindings|BindingsScripts": [ "[email protected]", "[email protected]", "[email protected]" ],
-        "WTF": [ "[email protected]", "[email protected]"],
+        "WTF": [ "[email protected]", "[email protected]"],
         "WatchListScript": [ "[email protected]", ],
         "WebGL": [ "[email protected]" ],
-        "WebIDL": [ "[email protected]", "[email protected]" ],
+        "WebIDL": [ "[email protected]", "[email protected]" ],
         "WebInspectorAPI": [ "[email protected]", "[email protected]" ],
         "WebKitGTKTranslations": [ "[email protected]", "[email protected]" ],
         "WebSocket": [ "[email protected]" ],
-        "XSS": [ "[email protected]", "[email protected]" ],
+        "XSS": [ "[email protected]", "[email protected]" ],
         "webkitperl": [ "[email protected]" ],
         "webkitpy": [ "[email protected]", "[email protected]" ],
     },

Modified: trunk/Tools/Scripts/webkitpy/common/watchlist/watchlistparser.py (136874 => 136875)


--- trunk/Tools/Scripts/webkitpy/common/watchlist/watchlistparser.py	2012-12-06 20:40:24 UTC (rev 136874)
+++ trunk/Tools/Scripts/webkitpy/common/watchlist/watchlistparser.py	2012-12-06 21:09:58 UTC (rev 136875)
@@ -152,7 +152,7 @@
             # modifying a list while iterating through it leads to undefined behavior.
             intructions_copy = cc_rule.instructions()[:]
             for email in intructions_copy:
-                if not accounts.account_by_login(email):
+                if not accounts.account_by_email(email):
                     cc_rule.remove_instruction(email)
                     self._log_error("The email alias %s which is in the watchlist is not listed as a contributor in committers.py" % email)
                     continue

Modified: trunk/Tools/Scripts/webkitpy/common/watchlist/watchlistparser_unittest.py (136874 => 136875)


--- trunk/Tools/Scripts/webkitpy/common/watchlist/watchlistparser_unittest.py	2012-12-06 20:40:24 UTC (rev 136874)
+++ trunk/Tools/Scripts/webkitpy/common/watchlist/watchlistparser_unittest.py	2012-12-06 21:09:58 UTC (rev 136875)
@@ -185,6 +185,23 @@
                                        expected_logs='The email alias [email protected] which is'
                                        + ' in the watchlist is not listed as a contributor in committers.py\n')
 
+    def test_cc_rule_with_secondary_email(self):
+        # FIXME: We should provide a mock of CommitterList so that we can test this on fake data.
+        watch_list = (
+            '{'
+            '    "DEFINITIONS": {'
+            '        "WatchList1": {'
+            '            "filename": r".*\\MyFileName\\.cpp",'
+            '        },'
+            '     },'
+            '    "CC_RULES": {'
+            '        "WatchList1": ["[email protected]"],'
+            '     },'
+            '}')
+
+        OutputCapture().assert_outputs(self, self._watch_list_parser.parse, args=[watch_list],
+                                       expected_logs='')
+
     def test_empty_message_rule(self):
         watch_list = (
             '{'
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to