An EWS run that has leak test failures does not correctly add bugzilla comments showi...
authorsimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 6 Sep 2018 22:25:59 +0000 (22:25 +0000)
committersimon.fraser@apple.com <simon.fraser@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 6 Sep 2018 22:25:59 +0000 (22:25 +0000)
https://bugs.webkit.org/show_bug.cgi?id=189368

Reviewed by Alexey Proskuryakov.

Include FailureDocumentLeak in ALL_FAILURE_CLASSES (with a fairly redundant test),
which should fix EWS showing leaks in Bugzilla.

* Scripts/webkitpy/layout_tests/models/test_failures.py:
(FailureDocumentLeak.__init__):
* Scripts/webkitpy/layout_tests/models/test_failures_unittest.py:
(TestFailuresTest.test_all_failure_classes):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@235761 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Tools/ChangeLog
Tools/Scripts/webkitpy/layout_tests/models/test_failures.py
Tools/Scripts/webkitpy/layout_tests/models/test_failures_unittest.py

index 9fd756b..612bf57 100644 (file)
@@ -1,3 +1,18 @@
+2018-09-06  Simon Fraser  <simon.fraser@apple.com>
+
+        An EWS run that has leak test failures does not correctly add bugzilla comments showing the failures
+        https://bugs.webkit.org/show_bug.cgi?id=189368
+
+        Reviewed by Alexey Proskuryakov.
+        
+        Include FailureDocumentLeak in ALL_FAILURE_CLASSES (with a fairly redundant test),
+        which should fix EWS showing leaks in Bugzilla.
+
+        * Scripts/webkitpy/layout_tests/models/test_failures.py:
+        (FailureDocumentLeak.__init__):
+        * Scripts/webkitpy/layout_tests/models/test_failures_unittest.py:
+        (TestFailuresTest.test_all_failure_classes):
+
 2018-09-06  Commit Queue  <commit-queue@webkit.org>
 
         Unreviewed, rolling out r235755.
index b7476ca..d95da02 100644 (file)
@@ -171,7 +171,7 @@ class FailureLeak(TestFailure):
 
 
 class FailureDocumentLeak(FailureLeak):
-    def __init__(self, leaked_document_urls):
+    def __init__(self, leaked_document_urls=None):
         super(FailureDocumentLeak, self).__init__()
         self.leaked_document_urls = leaked_document_urls
 
@@ -295,5 +295,5 @@ ALL_FAILURE_CLASSES = (FailureTimeout, FailureCrash, FailureMissingResult, Failu
                        FailureMissingImage, FailureImageHashMismatch,
                        FailureImageHashIncorrect, FailureReftestMismatch,
                        FailureReftestMismatchDidNotOccur, FailureReftestNoImagesGenerated,
-                       FailureMissingAudio, FailureAudioMismatch,
+                       FailureMissingAudio, FailureAudioMismatch, FailureDocumentLeak,
                        FailureEarlyExit)
index f5640d1..30f1dc7 100644 (file)
@@ -59,6 +59,26 @@ class TestFailuresTest(unittest.TestCase):
         for c in ALL_FAILURE_CLASSES:
             self.assert_loads(c)
 
+    def test_all_failure_classes(self):
+        failure_classes = (
+            FailureTimeout,
+            FailureCrash,
+            FailureMissingResult,
+            FailureNotTested,
+            FailureTextMismatch,
+            FailureMissingImageHash,
+            FailureMissingImage,
+            FailureImageHashMismatch,
+            FailureImageHashIncorrect,
+            FailureReftestMismatch,
+            FailureReftestMismatchDidNotOccur,
+            FailureReftestNoImagesGenerated,
+            FailureMissingAudio,
+            FailureAudioMismatch,
+            FailureDocumentLeak,
+            FailureEarlyExit)
+        self.assertEqual(failure_classes, ALL_FAILURE_CLASSES)
+
     def test_equals(self):
         self.assertEqual(FailureCrash(), FailureCrash())
         self.assertNotEqual(FailureCrash(), FailureTimeout())