aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit
diff options
context:
space:
mode:
authorDan Finlay <dan@danfinlay.com>2017-05-12 08:15:45 +0800
committerDan Finlay <dan@danfinlay.com>2017-05-12 08:15:45 +0800
commitde5cf2526ca3b3791545afc32d90a3bb88a8b8e3 (patch)
tree116ea08a1ccfb8ac1efcd3b92f28d472d85a2339 /test/unit
parent60746a985997693612af0c8b43aac95b2a6e56e6 (diff)
downloadtangerine-wallet-browser-de5cf2526ca3b3791545afc32d90a3bb88a8b8e3.tar
tangerine-wallet-browser-de5cf2526ca3b3791545afc32d90a3bb88a8b8e3.tar.gz
tangerine-wallet-browser-de5cf2526ca3b3791545afc32d90a3bb88a8b8e3.tar.bz2
tangerine-wallet-browser-de5cf2526ca3b3791545afc32d90a3bb88a8b8e3.tar.lz
tangerine-wallet-browser-de5cf2526ca3b3791545afc32d90a3bb88a8b8e3.tar.xz
tangerine-wallet-browser-de5cf2526ca3b3791545afc32d90a3bb88a8b8e3.tar.zst
tangerine-wallet-browser-de5cf2526ca3b3791545afc32d90a3bb88a8b8e3.zip
Fix test up a bit
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/components/pending-tx-test.js10
1 files changed, 4 insertions, 6 deletions
diff --git a/test/unit/components/pending-tx-test.js b/test/unit/components/pending-tx-test.js
index caaf66b49..5ddea7b23 100644
--- a/test/unit/components/pending-tx-test.js
+++ b/test/unit/components/pending-tx-test.js
@@ -7,7 +7,6 @@ console.dir(createReactFactory)
const shallow = require('enzyme').shallow
const Factory = createReactFactory(PendingTx)
const ReactTestUtils = require('react-addons-test-utils')
-const renderer = ReactTestUtils.createRenderer();
describe.only('PendingTx', function () {
let pendingTxComponent
@@ -38,6 +37,7 @@ describe.only('PendingTx', function () {
it('should use updated values when edited.', function (done) {
+ const renderer = ReactTestUtils.createRenderer();
const newGasPrice = '0x451456'
const props = {
@@ -53,7 +53,9 @@ describe.only('PendingTx', function () {
const pendingTxComponent = h(PendingTx, props)
renderer.render(pendingTxComponent)
- console.dir(pendingTxComponent)
+ const result = renderer.getRenderOutput()
+ assert.equal(result.type, 'div', 'should create a div')
+ console.dir(result)
const noop = () => {}
@@ -67,10 +69,6 @@ describe.only('PendingTx', function () {
// Click the submit button
// Get the output of the submit event.
- setTimeout(() => {
- console.log('hitting submit')
- pendingTxComponent.onSubmit({ preventDefault: noop })
- }, 20)
}, 200)
console.log('calling render')