Title: [100644] trunk/Tools
Revision
100644
Author
aro...@apple.com
Date
2011-11-17 10:55:37 -0800 (Thu, 17 Nov 2011)

Log Message

Remove extra quoting of call stacks and types passed to run-leaks by NRWT

Fixes <http://webkit.org/b/72623> REGRESSION (NRWT): run-webkit-tests --leaks reports leaks
that are supposed to be ignored

Reviewed by Adam Barth.

* Scripts/webkitpy/layout_tests/port/leakdetector.py:
(LeakDetector._leaks_args): Removed extra quoting of call stacks and types. Quoting is only
required when passing arguments via the shell (which we aren't doing here). It is not
required by Perl's option-parsing code (as the comment I removed mistakenly claimed).

* Scripts/webkitpy/layout_tests/port/leakdetector_unittest.py:
(LeakDetectorTest.test_leaks_args): Updated expectations.

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (100643 => 100644)


--- trunk/Tools/ChangeLog	2011-11-17 18:29:44 UTC (rev 100643)
+++ trunk/Tools/ChangeLog	2011-11-17 18:55:37 UTC (rev 100644)
@@ -1,3 +1,20 @@
+2011-11-17  Adam Roben  <aro...@apple.com>
+
+        Remove extra quoting of call stacks and types passed to run-leaks by NRWT
+
+        Fixes <http://webkit.org/b/72623> REGRESSION (NRWT): run-webkit-tests --leaks reports leaks
+        that are supposed to be ignored
+
+        Reviewed by Adam Barth.
+
+        * Scripts/webkitpy/layout_tests/port/leakdetector.py:
+        (LeakDetector._leaks_args): Removed extra quoting of call stacks and types. Quoting is only
+        required when passing arguments via the shell (which we aren't doing here). It is not
+        required by Perl's option-parsing code (as the comment I removed mistakenly claimed).
+
+        * Scripts/webkitpy/layout_tests/port/leakdetector_unittest.py:
+        (LeakDetectorTest.test_leaks_args): Updated expectations.
+
 2011-11-17  Philippe Normand  <pnorm...@igalia.com>
 
         Unreviewed, run-bindings-tests fix after r91028.

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/leakdetector.py (100643 => 100644)


--- trunk/Tools/Scripts/webkitpy/layout_tests/port/leakdetector.py	2011-11-17 18:29:44 UTC (rev 100643)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/leakdetector.py	2011-11-17 18:55:37 UTC (rev 100644)
@@ -87,9 +87,9 @@
     def _leaks_args(self, pid):
         leaks_args = []
         for callstack in self._callstacks_to_exclude_from_leaks():
-            leaks_args += ['--exclude-callstack="%s"' % callstack]  # Callstacks can have spaces in them, so we quote the arg to prevent confusing perl's optparse.
+            leaks_args += ['--exclude-callstack=%s' % callstack]
         for excluded_type in self._types_to_exlude_from_leaks():
-            leaks_args += ['--exclude-type="%s"' % excluded_type]
+            leaks_args += ['--exclude-type=%s' % excluded_type]
         leaks_args.append(pid)
         return leaks_args
 

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/leakdetector_unittest.py (100643 => 100644)


--- trunk/Tools/Scripts/webkitpy/layout_tests/port/leakdetector_unittest.py	2011-11-17 18:29:44 UTC (rev 100643)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/leakdetector_unittest.py	2011-11-17 18:55:37 UTC (rev 100644)
@@ -50,7 +50,7 @@
         detector = self._make_detector()
         detector._callstacks_to_exclude_from_leaks = lambda: ['foo bar', 'BAZ']
         detector._types_to_exlude_from_leaks = lambda: ['abcdefg', 'hi jklmno']
-        expected_args = ['--exclude-callstack="foo bar"', '--exclude-callstack="BAZ"', '--exclude-type="abcdefg"', '--exclude-type="hi jklmno"', 1234]
+        expected_args = ['--exclude-callstack=foo bar', '--exclude-callstack=BAZ', '--exclude-type=abcdefg', '--exclude-type=hi jklmno', 1234]
         self.assertEquals(detector._leaks_args(1234), expected_args)
 
     example_leaks_output = """Process 5122: 663744 nodes malloced for 78683 KB
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to