From 7799883adc49e01f12a32045cab3d8483c55a354 Mon Sep 17 00:00:00 2001 From: Jaco Greeff Date: Wed, 10 May 2017 14:31:55 +0200 Subject: [PATCH] Fix tests --- js/src/ui/Container/container.spec.js | 20 ------------------- .../awaitingDepositStep.spec.js | 2 +- .../awaitingExchangeStep.spec.js | 2 +- .../CompletedStep/completedStep.spec.js | 2 +- .../Shapeshift/ErrorStep/errorStep.spec.js | 2 +- .../OptionsStep/optionsSteps.spec.js | 4 ++-- .../Account/Shapeshift/Price/price.spec.js | 2 +- .../Account/Shapeshift/Value/value.spec.js | 2 +- .../Account/Shapeshift/shapeshift.spec.js | 2 +- 9 files changed, 9 insertions(+), 29 deletions(-) diff --git a/js/src/ui/Container/container.spec.js b/js/src/ui/Container/container.spec.js index 78b625e39..1fff66549 100644 --- a/js/src/ui/Container/container.spec.js +++ b/js/src/ui/Container/container.spec.js @@ -35,24 +35,4 @@ describe('ui/Container', () => { expect(render({ className: 'testClass' })).to.have.className('testClass'); }); }); - - describe('sections', () => { - it('renders the default Card', () => { - expect(render().find('Card')).to.have.length(1); - }); - - it('renders Hover Card when available', () => { - const cards = render({ hover:
testingHover
}).find('Card'); - - expect(cards).to.have.length(2); - expect(cards.get(1).props.children.props.children).to.equal('testingHover'); - }); - - it('renders the Title', () => { - const title = render({ title: 'title' }).find('Title'); - - expect(title).to.have.length(1); - expect(title.props().title).to.equal('title'); - }); - }); }); diff --git a/js/src/views/Account/Shapeshift/AwaitingDepositStep/awaitingDepositStep.spec.js b/js/src/views/Account/Shapeshift/AwaitingDepositStep/awaitingDepositStep.spec.js index 2e8cedf28..58fc41664 100644 --- a/js/src/views/Account/Shapeshift/AwaitingDepositStep/awaitingDepositStep.spec.js +++ b/js/src/views/Account/Shapeshift/AwaitingDepositStep/awaitingDepositStep.spec.js @@ -38,7 +38,7 @@ function render () { return component; } -describe('modals/Shapeshift/AwaitingDepositStep', () => { +describe('views/Account/Shapeshift/AwaitingDepositStep', () => { it('renders defaults', () => { expect(render()).to.be.ok; }); diff --git a/js/src/views/Account/Shapeshift/AwaitingExchangeStep/awaitingExchangeStep.spec.js b/js/src/views/Account/Shapeshift/AwaitingExchangeStep/awaitingExchangeStep.spec.js index 0433bfb56..253660e46 100644 --- a/js/src/views/Account/Shapeshift/AwaitingExchangeStep/awaitingExchangeStep.spec.js +++ b/js/src/views/Account/Shapeshift/AwaitingExchangeStep/awaitingExchangeStep.spec.js @@ -33,7 +33,7 @@ function render () { return component; } -describe('modals/Shapeshift/AwaitingExchangeStep', () => { +describe('views/Account/Shapeshift/AwaitingExchangeStep', () => { it('renders defaults', () => { expect(render()).to.be.ok; }); diff --git a/js/src/views/Account/Shapeshift/CompletedStep/completedStep.spec.js b/js/src/views/Account/Shapeshift/CompletedStep/completedStep.spec.js index 4a51c7561..51b553a8e 100644 --- a/js/src/views/Account/Shapeshift/CompletedStep/completedStep.spec.js +++ b/js/src/views/Account/Shapeshift/CompletedStep/completedStep.spec.js @@ -34,7 +34,7 @@ function render () { return component; } -describe('modals/Shapeshift/CompletedStep', () => { +describe('views/Account/Shapeshift/CompletedStep', () => { it('renders defaults', () => { expect(render()).to.be.ok; }); diff --git a/js/src/views/Account/Shapeshift/ErrorStep/errorStep.spec.js b/js/src/views/Account/Shapeshift/ErrorStep/errorStep.spec.js index 92086a1eb..515eaf1a0 100644 --- a/js/src/views/Account/Shapeshift/ErrorStep/errorStep.spec.js +++ b/js/src/views/Account/Shapeshift/ErrorStep/errorStep.spec.js @@ -33,7 +33,7 @@ function render () { return component; } -describe('modals/Shapeshift/ErrorStep', () => { +describe('views/Account/Shapeshift/ErrorStep', () => { it('renders defaults', () => { expect(render()).to.be.ok; }); diff --git a/js/src/views/Account/Shapeshift/OptionsStep/optionsSteps.spec.js b/js/src/views/Account/Shapeshift/OptionsStep/optionsSteps.spec.js index e0a71752e..d4d158d54 100644 --- a/js/src/views/Account/Shapeshift/OptionsStep/optionsSteps.spec.js +++ b/js/src/views/Account/Shapeshift/OptionsStep/optionsSteps.spec.js @@ -38,7 +38,7 @@ function render () { return component; } -describe('modals/Shapeshift/OptionsStep', () => { +describe('views/Account/Shapeshift/OptionsStep', () => { beforeEach(() => { render(); }); @@ -103,7 +103,7 @@ describe('modals/Shapeshift/OptionsStep', () => { }); it('sets the coinSymbol on the store', () => { - instance.onSelectCoin(null, 0, 'XMR'); + instance.onSelectCoin(null, { value: 'XMR' }); expect(store.setCoinSymbol).to.have.been.calledWith('XMR'); }); }); diff --git a/js/src/views/Account/Shapeshift/Price/price.spec.js b/js/src/views/Account/Shapeshift/Price/price.spec.js index 4c815b652..98ffa351f 100644 --- a/js/src/views/Account/Shapeshift/Price/price.spec.js +++ b/js/src/views/Account/Shapeshift/Price/price.spec.js @@ -34,7 +34,7 @@ function render (props = {}) { return component; } -describe('modals/Shapeshift/Price', () => { +describe('views/Account/Shapeshift/Price', () => { it('renders defaults', () => { expect(render()).to.be.ok; }); diff --git a/js/src/views/Account/Shapeshift/Value/value.spec.js b/js/src/views/Account/Shapeshift/Value/value.spec.js index f4b1f646e..950dc3fb8 100644 --- a/js/src/views/Account/Shapeshift/Value/value.spec.js +++ b/js/src/views/Account/Shapeshift/Value/value.spec.js @@ -29,7 +29,7 @@ function render (props = {}) { return component; } -describe('modals/Shapeshift/Value', () => { +describe('views/Account/Shapeshift/Value', () => { it('renders defaults', () => { expect(render()).to.be.ok; }); diff --git a/js/src/views/Account/Shapeshift/shapeshift.spec.js b/js/src/views/Account/Shapeshift/shapeshift.spec.js index b591de390..e539f889e 100644 --- a/js/src/views/Account/Shapeshift/shapeshift.spec.js +++ b/js/src/views/Account/Shapeshift/shapeshift.spec.js @@ -42,7 +42,7 @@ function render (props = {}) { return component; } -describe('modals/Shapeshift', () => { +describe('views/Account/Shapeshift', () => { it('renders defaults', () => { expect(render()).to.be.ok; });