Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Commit

Permalink
Fix broken unit test for new payments tab component
Browse files Browse the repository at this point in the history
This reverts commit 897cebb.
Fixes #6891
Partially fixes #6911

Auditors: @bbondy

Test Plan:
`npm run test -- --grep="PaymentsTab component"`
  • Loading branch information
bsclifton committed Jan 30, 2017
1 parent 2aa39bb commit 93436ea
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions test/unit/app/renderer/paymentsTabTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,12 @@ describe('PaymentsTab component', function () {
assert.equal(wrapper.find('[data-test-id="creatingWallet"]').length, 1)
})

it.skip('renders payment history button', function () {
it('renders payment history button (requires wallet and reconcileStamp)', function () {
const wrapper = shallow(
<PaymentsTab
showOverlay={function () {}}
hideOverlay={function () {}}
ledgerData={Immutable.Map({created: true, transactions: {size: 3}})} />
ledgerData={Immutable.Map({created: true, transactions: {size: 3}, reconcileStamp: 1})} />
)
assert.equal(wrapper.find('.paymentHistoryButton').length, 1)
})
Expand All @@ -123,6 +123,16 @@ describe('PaymentsTab component', function () {
)
assert.equal(wrapper.find('.paymentHistoryButton').length, 0)
})

it('does not render payment history button when reconcileStamp is not set', function () {
const wrapper = shallow(
<PaymentsTab
showOverlay={function () {}}
hideOverlay={function () {}}
ledgerData={Immutable.Map({created: true, transactions: {size: 3}})} />
)
assert.equal(wrapper.find('.paymentHistoryButton').length, 0)
})
})

describe('fundsamount functionality', function () {
Expand Down

0 comments on commit 93436ea

Please sign in to comment.