aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorKevin Serrano <kevin.serrano@consensys.net>2017-05-24 05:26:37 +0800
committerKevin Serrano <kevin.serrano@consensys.net>2017-05-24 05:26:37 +0800
commit31d17c9e25458cd47f8c18ec3b967aecff236ba6 (patch)
treecc933238d05bd3d32f2a2db3bfd4209617998800 /test
parent97d19f0f7970feb6fb3170fd85211d0c765cabea (diff)
downloadtangerine-wallet-browser-31d17c9e25458cd47f8c18ec3b967aecff236ba6.tar
tangerine-wallet-browser-31d17c9e25458cd47f8c18ec3b967aecff236ba6.tar.gz
tangerine-wallet-browser-31d17c9e25458cd47f8c18ec3b967aecff236ba6.tar.bz2
tangerine-wallet-browser-31d17c9e25458cd47f8c18ec3b967aecff236ba6.tar.lz
tangerine-wallet-browser-31d17c9e25458cd47f8c18ec3b967aecff236ba6.tar.xz
tangerine-wallet-browser-31d17c9e25458cd47f8c18ec3b967aecff236ba6.tar.zst
tangerine-wallet-browser-31d17c9e25458cd47f8c18ec3b967aecff236ba6.zip
Fix test, create new value for precision/scale
Diffstat (limited to 'test')
-rw-r--r--test/unit/components/bn-as-decimal-input-test.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/unit/components/bn-as-decimal-input-test.js b/test/unit/components/bn-as-decimal-input-test.js
index f515003bb..6fe684dc5 100644
--- a/test/unit/components/bn-as-decimal-input-test.js
+++ b/test/unit/components/bn-as-decimal-input-test.js
@@ -10,7 +10,6 @@ var BnInput = require('../../../ui/app/components/bn-as-decimal-input')
describe('BnInput', function () {
it('can tolerate a gas decimal number at a high precision', function (done) {
-
const renderer = ReactTestUtils.createRenderer()
let valueStr = '20'
@@ -27,10 +26,12 @@ describe('BnInput', function () {
}
const target = new BN(targetStr, 10)
- const precision = 1e18 // ether precision
+ const precision = 13 // ether precision
+ const scale = 13
const props = {
value,
+ scale,
precision,
onChange: (newBn) => {
assert.equal(newBn.toString(), target.toString(), 'should tolerate increase')