Bug 1131862 - mcMerge: Rename products to hasTestsuiteFlag
authorEd Morley <emorley@mozilla.com>
Tue, 24 Feb 2015 09:30:44 +0000
changeset 1505 322347863a53
parent 1504 052e24e0e7a5
child 1506 3b92d0e89f8f
push id872
push useremorley@mozilla.com
push dateTue, 24 Feb 2015 23:11:31 +0000
bugs1131862
Bug 1131862 - mcMerge: Rename products to hasTestsuiteFlag For consistency with ConfigurationData.milestones
mcmerge/js/BugData.js
mcmerge/js/ConfigurationData.js
--- a/mcmerge/js/BugData.js
+++ b/mcmerge/js/BugData.js
@@ -106,17 +106,17 @@ var BugData = {
     bug.statusFlag = '---';
     if (this.statusFlag)
       bug.statusFlag = bugObj[this.statusFlag];
 
     bug.isUnassigned = bugObj.assigned_to.name == 'nobody';
 
     bug.intestsuite = ' ';
     bug.testsuiteFlagID = -1;
-    bug.canSetTestsuite = ConfigurationData.products[bug.product][bugObj.component];
+    bug.canSetTestsuite = ConfigurationData.hasTestsuiteFlag[bug.product][bugObj.component];
     if (bug.canSetTestsuite && 'flags' in bugObj && bugObj.flags) {
       for (var i = 0; i < bugObj.flags.length; i++) {
         var f = bugObj.flags[i];
         if (f.name == 'in-testsuite' && f.type_id == ConfigurationData.testsuiteFlagID) {
           bug.intestsuite = f.status; 
           bug.testsuiteFlagID = f.id;
           break;
         }
--- a/mcmerge/js/ConfigurationData.js
+++ b/mcmerge/js/ConfigurationData.js
@@ -1,13 +1,13 @@
 "use strict";
 
 var ConfigurationData = {
   milestones: {},
-  products: {},
+  hasTestsuiteFlag: {},
   testsuiteFlagID: -1,
 
   // useNext represents products where I'm reasonably
   // confident that the correct milestone is --- + 1
   useNext: ['Add-on SDK',
             'Android Background Services',
             'Core',
             'Fennec',
@@ -68,19 +68,19 @@ var ConfigurationData = {
           break;
         }
       }
     }
 
     // Find which products/components can have intestsuite set
     if ('product' in data && this.testsuiteFlagID != -1) {
       for (var product in data.product) {
-        this.products[product] = {};
+        this.hasTestsuiteFlag[product] = {};
         for (var component in data.product[product].component) {
           var hasTestsuite = data.product[product].component[component].flag_type.indexOf(this.testsuiteFlagID) != -1;
-          this.products[product][component] = hasTestsuite;
+          this.hasTestsuiteFlag[product][component] = hasTestsuite;
         }
       }
     }
 
     loadCallback();
   }
 };