Should not mark a platform as missing in summary page if all expecting metrics are...
authordewei_zhu@apple.com <dewei_zhu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 16 Sep 2017 01:11:27 +0000 (01:11 +0000)
committerdewei_zhu@apple.com <dewei_zhu@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 16 Sep 2017 01:11:27 +0000 (01:11 +0000)
https://bugs.webkit.org/show_bug.cgi?id=176970

Reviewed by Ryosuke Niwa.

In summary page, if all metrics for a test are excluded in excludedConfigurations for a platform, this platform should not be marked as missing.

* public/v3/pages/summary-page.js:
(SummaryPageConfigurationGroup):

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

Websites/perf.webkit.org/ChangeLog
Websites/perf.webkit.org/public/v3/pages/summary-page.js

index 409ec28..f48ce63 100644 (file)
@@ -1,3 +1,15 @@
+2017-09-15  Dewei Zhu  <dewei_zhu@apple.com>
+
+        Should not mark a platform as missing in summary page if all expecting metrics are exlucded.
+        https://bugs.webkit.org/show_bug.cgi?id=176970
+
+        Reviewed by Ryosuke Niwa.
+
+        In summary page, if all metrics for a test are excluded in excludedConfigurations for a platform, this platform should not be marked as missing.
+
+        * public/v3/pages/summary-page.js:
+        (SummaryPageConfigurationGroup):
+
 2017-09-11  Ryosuke Niwa  <rniwa@webkit.org>
 
         Analysis task page shows an empty results for an irrelevant top-level test
index 9515b17..05c6013 100644 (file)
@@ -259,23 +259,26 @@ class SummaryPageConfigurationGroup {
         this._isFetching = false;
         this._smallerIsBetter = metrics.length ? metrics[0].isSmallerBetter() : null;
 
-        for (var platform of platforms) {
+        for (const platform of platforms) {
             console.assert(platform instanceof Platform);
-            var foundInSomeMetric = false;
-            for (var metric of metrics) {
+            let foundInSomeMetric = false;
+            let excludedMerticCount = 0;
+            for (const metric of metrics) {
                 console.assert(metric instanceof Metric);
                 console.assert(this._smallerIsBetter == metric.isSmallerBetter());
                 metric.isSmallerBetter();
 
-                if (excludedConfigurations && platform.id() in excludedConfigurations && excludedConfigurations[platform.id()].includes(+metric.id()))
+                if (excludedConfigurations && platform.id() in excludedConfigurations && excludedConfigurations[platform.id()].includes(+metric.id())) {
+                    excludedMerticCount += 1;
                     continue;
+                }
                 if (!platform.hasMetric(metric))
                     continue;
                 foundInSomeMetric = true;
                 this._measurementSets.push(MeasurementSet.findSet(platform.id(), metric.id(), platform.lastModified(metric)));
                 this._configurationList.push([platform.id(), metric.id()]);
             }
-            if (!foundInSomeMetric)
+            if (!foundInSomeMetric && excludedMerticCount < metrics.length)
                 this._missingPlatforms.add(platform);
         }
     }