|
@@ -121,12 +121,6 @@ describe('App.WizardStep3Controller', function () {
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERING', isChecked: false})
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERING', isChecked: false})
|
|
],
|
|
],
|
|
m: 'One registered, one registering',
|
|
m: 'One registered, one registering',
|
|
- allHostsComplete: {
|
|
|
|
- e: false
|
|
|
|
- },
|
|
|
|
- isInstallInProgress: {
|
|
|
|
- e: true
|
|
|
|
- },
|
|
|
|
visibleHosts: {
|
|
visibleHosts: {
|
|
RUNNING: {
|
|
RUNNING: {
|
|
e: 0
|
|
e: 0
|
|
@@ -151,12 +145,6 @@ describe('App.WizardStep3Controller', function () {
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERED', isChecked: false})
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERED', isChecked: false})
|
|
],
|
|
],
|
|
m: 'Two registered',
|
|
m: 'Two registered',
|
|
- allHostsComplete: {
|
|
|
|
- e: true
|
|
|
|
- },
|
|
|
|
- isInstallInProgress: {
|
|
|
|
- e: false
|
|
|
|
- },
|
|
|
|
visibleHosts: {
|
|
visibleHosts: {
|
|
RUNNING: {
|
|
RUNNING: {
|
|
e: 0
|
|
e: 0
|
|
@@ -181,12 +169,6 @@ describe('App.WizardStep3Controller', function () {
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERED', isChecked: false})
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERED', isChecked: false})
|
|
],
|
|
],
|
|
m: 'One registered, one failed',
|
|
m: 'One registered, one failed',
|
|
- allHostsComplete: {
|
|
|
|
- e: true
|
|
|
|
- },
|
|
|
|
- isInstallInProgress: {
|
|
|
|
- e: false
|
|
|
|
- },
|
|
|
|
visibleHosts: {
|
|
visibleHosts: {
|
|
RUNNING: {
|
|
RUNNING: {
|
|
e: 0
|
|
e: 0
|
|
@@ -211,12 +193,6 @@ describe('App.WizardStep3Controller', function () {
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'FAILED', isChecked: false})
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'FAILED', isChecked: false})
|
|
],
|
|
],
|
|
m: 'Two failed',
|
|
m: 'Two failed',
|
|
- allHostsComplete: {
|
|
|
|
- e: true
|
|
|
|
- },
|
|
|
|
- isInstallInProgress: {
|
|
|
|
- e: false
|
|
|
|
- },
|
|
|
|
visibleHosts: {
|
|
visibleHosts: {
|
|
RUNNING: {
|
|
RUNNING: {
|
|
e: 0
|
|
e: 0
|
|
@@ -241,12 +217,6 @@ describe('App.WizardStep3Controller', function () {
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERING', isChecked: false})
|
|
Em.Object.create({name:'wst3_host2', bootStatus: 'REGISTERING', isChecked: false})
|
|
],
|
|
],
|
|
m: 'Two registering',
|
|
m: 'Two registering',
|
|
- allHostsComplete: {
|
|
|
|
- e: false
|
|
|
|
- },
|
|
|
|
- isInstallInProgress: {
|
|
|
|
- e: true
|
|
|
|
- },
|
|
|
|
visibleHosts: {
|
|
visibleHosts: {
|
|
RUNNING: {
|
|
RUNNING: {
|
|
e: 0
|
|
e: 0
|
|
@@ -267,28 +237,6 @@ describe('App.WizardStep3Controller', function () {
|
|
}
|
|
}
|
|
];
|
|
];
|
|
|
|
|
|
- describe('#allHostsComplete', function() {
|
|
|
|
- tests.forEach(function(test) {
|
|
|
|
- var controller = App.WizardStep3Controller.create({
|
|
|
|
- bootHosts: test.bootHosts
|
|
|
|
- });
|
|
|
|
- it(test.m, function() {
|
|
|
|
- expect(controller.get('allHostsComplete')).to.equal(test.allHostsComplete.e);
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
-
|
|
|
|
- describe('#isInstallInProgress', function() {
|
|
|
|
- tests.forEach(function(test) {
|
|
|
|
- var controller = App.WizardStep3Controller.create({
|
|
|
|
- bootHosts: test.bootHosts
|
|
|
|
- });
|
|
|
|
- it(test.m, function() {
|
|
|
|
- expect(controller.get('isInstallInProgress')).to.equal(test.isInstallInProgress.e);
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
-
|
|
|
|
describe('#registrationTimeoutSecs', function() {
|
|
describe('#registrationTimeoutSecs', function() {
|
|
it('Manual install', function() {
|
|
it('Manual install', function() {
|
|
var controller = App.WizardStep3Controller.create({
|
|
var controller = App.WizardStep3Controller.create({
|
|
@@ -312,30 +260,6 @@ describe('App.WizardStep3Controller', function () {
|
|
});
|
|
});
|
|
});
|
|
});
|
|
|
|
|
|
- describe('#visibleHosts', function() {
|
|
|
|
- var c = ['RUNNING', 'REGISTERING', 'REGISTERED', 'FAILED'];
|
|
|
|
- tests.forEach(function(test) {
|
|
|
|
- describe(test.m, function() {
|
|
|
|
- c.forEach(function(_c) {
|
|
|
|
- var controller = App.WizardStep3Controller.create({
|
|
|
|
- hosts: test.bootHosts
|
|
|
|
- });
|
|
|
|
- controller.set('category', {hostsBootStatus: _c});
|
|
|
|
- it(_c, function() {
|
|
|
|
- expect(controller.get('visibleHosts').length).to.equal(test.visibleHosts[_c].e);
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
- var controller = App.WizardStep3Controller.create({
|
|
|
|
- hosts: test.bootHosts
|
|
|
|
- });
|
|
|
|
- controller.set('category', false);
|
|
|
|
- it('ALL', function() {
|
|
|
|
- expect(controller.get('visibleHosts').length).to.equal(test.bootHosts.length);
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
-
|
|
|
|
describe('#isHostHaveWarnings', function() {
|
|
describe('#isHostHaveWarnings', function() {
|
|
var tests = [
|
|
var tests = [
|
|
{
|
|
{
|
|
@@ -358,18 +282,6 @@ describe('App.WizardStep3Controller', function () {
|
|
});
|
|
});
|
|
});
|
|
});
|
|
|
|
|
|
- describe('#onAllChecked', function() {
|
|
|
|
- tests.forEach(function(test) {
|
|
|
|
- var controller = App.WizardStep3Controller.create({
|
|
|
|
- hosts: test.bootHosts
|
|
|
|
- });
|
|
|
|
- controller.set('allChecked', true);
|
|
|
|
- it(test.m, function() {
|
|
|
|
- expect(controller.get('visibleHosts').getEach('isChecked')).to.eql(test.onAllChecked.e);
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
- });
|
|
|
|
-
|
|
|
|
describe('#noHostsSelected', function() {
|
|
describe('#noHostsSelected', function() {
|
|
tests.forEach(function(test) {
|
|
tests.forEach(function(test) {
|
|
it(test.m + ' - nothing checked', function() {
|
|
it(test.m + ' - nothing checked', function() {
|