You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by on...@apache.org on 2016/03/10 09:08:53 UTC

ambari git commit: AMBARI-15350. Typo in the dependent key (onechiporenko)

Repository: ambari
Updated Branches:
  refs/heads/trunk 26b335790 -> 0c44129ad


AMBARI-15350. Typo in the dependent key (onechiporenko)


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

Branch: refs/heads/trunk
Commit: 0c44129ad18fc6c30e1f49ffa0580fd2d64c3351
Parents: 26b3357
Author: Oleg Nechiporenko <on...@apache.org>
Authored: Wed Mar 9 14:22:01 2016 +0200
Committer: Oleg Nechiporenko <on...@apache.org>
Committed: Thu Mar 10 10:06:52 2016 +0200

----------------------------------------------------------------------
 .../controllers/main/service/info/configs.js    |  2 +-
 .../widgets/create/wizard_controller_test.js    | 11 ++++-------
 ambari-web/test/controllers/main_test.js        | 20 +++++++-------------
 3 files changed, 12 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/0c44129a/ambari-web/app/controllers/main/service/info/configs.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/service/info/configs.js b/ambari-web/app/controllers/main/service/info/configs.js
index a22bb48..85346d6 100644
--- a/ambari-web/app/controllers/main/service/info/configs.js
+++ b/ambari-web/app/controllers/main/service/info/configs.js
@@ -53,7 +53,7 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.ConfigsLoader, A
     return this.get('groupsStore').filter(function(group) {
       return this.get('dependentServiceNames').contains(group.get('serviceName'));
     }, this);
-  }.property('content.serviceName', 'dependentServiceNames', 'groupsStore.length', 'groupStore.@each.name'),
+  }.property('content.serviceName', 'dependentServiceNames', 'groupsStore.length', 'groupsStore.@each.name'),
 
   allConfigs: [],
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/0c44129a/ambari-web/test/controllers/main/service/widgets/create/wizard_controller_test.js
----------------------------------------------------------------------
diff --git a/ambari-web/test/controllers/main/service/widgets/create/wizard_controller_test.js b/ambari-web/test/controllers/main/service/widgets/create/wizard_controller_test.js
index 4733716..92d3642 100644
--- a/ambari-web/test/controllers/main/service/widgets/create/wizard_controller_test.js
+++ b/ambari-web/test/controllers/main/service/widgets/create/wizard_controller_test.js
@@ -36,16 +36,13 @@ describe('App.WidgetWizardController', function () {
   describe("#substitueQueueMetrics", function () {
     beforeEach(function () {
       controller = App.WidgetWizardController.create();
-      sinon.stub(App.YARNService, 'find', function (k) {
-        if ('YARN' === k) {
-          return Em.Object.create({
-            'allQueueNames': ["root", "root/queue1", "root/queue1/queue2", "root/queue1/queue3"]
-          });
-        }
+      sinon.stub(App.YARNService, 'find', function () {
+        return Em.Object.create({
+          'allQueueNames': ["root", "root/queue1", "root/queue1/queue2", "root/queue1/queue3"]
+        });
       });
     });
     afterEach(function () {
-      controller = '';
       App.YARNService.find.restore();
     });
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/0c44129a/ambari-web/test/controllers/main_test.js
----------------------------------------------------------------------
diff --git a/ambari-web/test/controllers/main_test.js b/ambari-web/test/controllers/main_test.js
index ce5e021..c026604 100644
--- a/ambari-web/test/controllers/main_test.js
+++ b/ambari-web/test/controllers/main_test.js
@@ -144,19 +144,13 @@ describe('App.MainController', function () {
 
   describe('#updateTitle', function() {
     beforeEach(function () {
-      sinon.stub(App.router, 'get', function(message){
-        if (message === 'clusterController.clusterName') {
-          return 'c1';
-        } else if (message === 'clusterInstallCompleted') {
-          return true;
-        } else if (message === 'clusterController') {
-          return {
-            get: function() {
-              return true;
-            }
-          };
-        }
-      });
+      sinon.stub(App.router, 'get').withArgs('clusterController.clusterName').returns('c1')
+        .withArgs('clusterInstallCompleted').returns(true)
+        .withArgs('clusterController').returns({
+          get: function() {
+            return true;
+          }
+        });
     });
     afterEach(function () {
       App.router.get.restore();