From 5e8a344f973fabb331db9b491247396117aa67b1 Mon Sep 17 00:00:00 2001 From: Dan Finlay Date: Fri, 23 Dec 2016 17:31:24 -0800 Subject: Correct getState test to be async --- test/unit/idStore-migration-test.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'test/unit') 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() + }) }) }) }) -- cgit v1.2.3