aboutsummaryrefslogtreecommitdiffstats
path: root/test/unit
diff options
context:
space:
mode:
authorDan Finlay <dan@danfinlay.com>2016-12-24 09:31:24 +0800
committerDan Finlay <dan@danfinlay.com>2016-12-24 10:40:36 +0800
commit5e8a344f973fabb331db9b491247396117aa67b1 (patch)
tree861d94df634622691b00bc400913d596db32694b /test/unit
parentc05e04c611f44ff8bef2f1d617cb79d2a5157f2a (diff)
downloadtangerine-wallet-browser-5e8a344f973fabb331db9b491247396117aa67b1.tar
tangerine-wallet-browser-5e8a344f973fabb331db9b491247396117aa67b1.tar.gz
tangerine-wallet-browser-5e8a344f973fabb331db9b491247396117aa67b1.tar.bz2
tangerine-wallet-browser-5e8a344f973fabb331db9b491247396117aa67b1.tar.lz
tangerine-wallet-browser-5e8a344f973fabb331db9b491247396117aa67b1.tar.xz
tangerine-wallet-browser-5e8a344f973fabb331db9b491247396117aa67b1.tar.zst
tangerine-wallet-browser-5e8a344f973fabb331db9b491247396117aa67b1.zip
Correct getState test to be async
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/idStore-migration-test.js11
1 files changed, 7 insertions, 4 deletions
diff --git a/test/unit/idStore-migration-test.js b/test/unit/idStore-migration-test.js
index 8532ac914..ad4ce2096 100644
--- a/test/unit/idStore-migration-test.js
+++ b/test/unit/idStore-migration-test.js
@@ -79,11 +79,14 @@ describe('IdentityStore to KeyringController migration', function() {
})
describe('entering a password', function() {
- it('should identify an old wallet as an initialized keyring', function() {
+ it('should identify an old wallet as an initialized keyring', function(done) {
keyringController.configManager.setWallet('something')
- const state = keyringController.getState()
- assert(state.isInitialized, 'old vault counted as initialized.')
- assert(!state.lostAccounts, 'no lost accounts')
+ keyringController.getState()
+ .then((state) => {
+ assert(state.isInitialized, 'old vault counted as initialized.')
+ assert(!state.lostAccounts, 'no lost accounts')
+ done()
+ })
})
})
})