ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From onechipore...@apache.org
Subject git commit: AMBARI-4807. Add Service link is active when all service are installed. (onechiporenko)
Date Mon, 24 Feb 2014 17:03:05 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 297fff3cf -> 84a88e5e4


AMBARI-4807. Add Service link is active when all service are installed. (onechiporenko)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/84a88e5e
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/84a88e5e
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/84a88e5e

Branch: refs/heads/trunk
Commit: 84a88e5e4ab0d26ba9fb3236590d82082ac83ead
Parents: 297fff3
Author: Oleg Nechiporenko <onechiporenko@apache.org>
Authored: Mon Feb 24 18:57:35 2014 +0200
Committer: Oleg Nechiporenko <onechiporenko@apache.org>
Committed: Mon Feb 24 18:57:35 2014 +0200

----------------------------------------------------------------------
 ambari-web/app/controllers/main/service.js |   3 +
 ambari-web/test/installer/step9_test.js    | 105 ------------------------
 2 files changed, 3 insertions(+), 105 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/84a88e5e/ambari-web/app/controllers/main/service.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/service.js b/ambari-web/app/controllers/main/service.js
index 27c26e2..030c045 100644
--- a/ambari-web/app/controllers/main/service.js
+++ b/ambari-web/app/controllers/main/service.js
@@ -41,6 +41,9 @@ App.MainServiceController = Em.ArrayController.extend({
       this.loadAvailableServices();
       availableServices = App.db.getServices();
     }
+    if (!App.supports.hue) {
+      availableServices = availableServices.without('HUE');
+    }
     return this.get('content.content').length == availableServices.length;
   }.property('content.content.@each', 'content.content.length'),
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/84a88e5e/ambari-web/test/installer/step9_test.js
----------------------------------------------------------------------
diff --git a/ambari-web/test/installer/step9_test.js b/ambari-web/test/installer/step9_test.js
index ae8deac..c8fdeeb 100644
--- a/ambari-web/test/installer/step9_test.js
+++ b/ambari-web/test/installer/step9_test.js
@@ -598,7 +598,6 @@ describe('App.InstallerStep9Controller', function () {
       expect(controller.get('hosts.length')).to.equal(0);
       expect(controller.get('status')).to.equal('info');
       expect(controller.get('progress')).to.equal('0');
-      expect(controller.get('isStepCompleted')).to.equal(false);
       expect(controller.get('numPolls')).to.equal(1);
     });
   });
@@ -774,110 +773,6 @@ describe('App.InstallerStep9Controller', function () {
     });
   });
 
-  describe('#setTasksPerHost', function () {
-    var tests = [
-      {
-        hosts: [
-          Em.Object.create({
-            name: 'host1',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          }),
-          Em.Object.create({
-            name: 'host2',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          }),
-          Em.Object.create({
-            name: 'host3',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          })
-        ],
-        polledData: [
-          {Tasks: {host_name: 'host1'}},
-          {Tasks: {host_name: 'host1'}},
-          {Tasks: {host_name: 'host1'}},
-          {Tasks: {host_name: 'host2'}},
-          {Tasks: {host_name: 'host2'}},
-          {Tasks: {host_name: 'host3'}}
-        ],
-        e: {
-          host1: {count: 3},
-          host2: {count: 2},
-          host3: {count: 1}
-        },
-        m: 'Several tasks for each host'
-      },
-      {
-        hosts: [
-          Em.Object.create({
-            name: 'host1',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          }),
-          Em.Object.create({
-            name: 'host2',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          }),
-          Em.Object.create({
-            name: 'host3',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          })
-        ],
-        polledData: [
-          {Tasks: {host_name: 'host1'}},
-          {Tasks: {host_name: 'host2'}}
-        ],
-        e: {
-          host1: {count: 1},
-          host2: {count: 1},
-          host3: {count: 0}
-        },
-        m: 'Some hosts without tasks'
-      },
-      {
-        hosts: Em.A([
-          Em.Object.create({
-            name: 'host1',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          }),
-          Em.Object.create({
-            name: 'host2',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          }),
-          Em.Object.create({
-            name: 'host3',
-            tasks: [],
-            bootStatus: 'REGISTERED'
-          })
-        ]),
-        polledData: [],
-        e: {
-          host1: {count: 0},
-          host2: {count: 0},
-          host3: {count: 0}
-        },
-        m: 'No tasks'
-      }
-    ];
-    tests.forEach(function (test) {
-      it(test.m, function () {
-        var controller = App.WizardStep9Controller.create({polledData: test.polledData, hosts:
test.hosts});
-        controller.setTasksPerHost();
-        for (var name in test.e.hosts) {
-          if (test.e.hosts.hasOwnProperty(name)) {
-            expect(controller.get('hosts').findProperty('name', name).get('tasks.length')).to.equal(test.e[name].count);
-          }
-        }
-      });
-    });
-  });
-
   describe('#setLogTasksStatePerHost', function () {
     var tests = [
       {


Mime
View raw message