Custom analysis task page should allow schedule any triggerable accepted tests.
authordewei_zhu@apple.com <dewei_zhu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 6 Dec 2019 22:49:02 +0000 (22:49 +0000)
committerdewei_zhu@apple.com <dewei_zhu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 6 Dec 2019 22:49:02 +0000 (22:49 +0000)
https://bugs.webkit.org/show_bug.cgi?id=204925

Reviewed by Ryosuke Niwa.

Fix a bug that subtest will not show on custom analysis task page if both itself and parent test are
accepted by triggerable.
Order test list in alphabetical order.

* public/v3/components/custom-analysis-task-configurator.js:
(CustomAnalysisTaskConfigurator.prototype._renderTriggerableTests):

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

Websites/perf.webkit.org/ChangeLog
Websites/perf.webkit.org/public/v3/components/custom-analysis-task-configurator.js

index 3dccc81..5f3c48e 100644 (file)
@@ -1,3 +1,17 @@
+2019-12-05  Dewei Zhu  <dewei_zhu@apple.com>
+
+        Custom analysis task page should allow schedule any triggerable accepted tests.
+        https://bugs.webkit.org/show_bug.cgi?id=204925
+
+        Reviewed by Ryosuke Niwa.
+
+        Fix a bug that subtest will not show on custom analysis task page if both itself and parent test are
+        accepted by triggerable.
+        Order test list in alphabetical order.
+
+        * public/v3/components/custom-analysis-task-configurator.js:
+        (CustomAnalysisTaskConfigurator.prototype._renderTriggerableTests):
+
 2019-10-28  Dewei Zhu  <dewei_zhu@apple.com>
 
         Fix a bug that cannot unhide a platform.
index e2c5342..37860be 100644 (file)
@@ -224,8 +224,11 @@ class CustomAnalysisTaskConfigurator extends ComponentBase {
             for (const test of triggerable.acceptedTests())
                 acceptedTests.add(test);
         }
-
-        let tests = Test.all().filter((test) => acceptedTests.has(test) && (!test.parentTest() || !acceptedTests.has(test.parentTest())));
+        const tests = [...acceptedTests].sort((testA, testB) => {
+            if (testA.fullName() == testB.fullName())
+                return 0;
+            return testA.fullName() < testB.fullName() ? -1 : 1;
+        });
         return this._renderRadioButtonList(this.content('test-list'), 'test', tests, this.selectTests.bind(this), (test) => test.fullName());
     }