one wallet by default

This commit is contained in:
Matias Alejo Garcia 2014-09-30 16:04:17 -03:00
commit 508a8bfc3c
6 changed files with 25 additions and 10 deletions

View file

@ -191,7 +191,7 @@ describe('Identity model', function() {
iden.createWallet({
privateKeyHex: priv,
}, function(err, w) {
Identity._newWallet.getCall(0).args[0].privateKey.toObj().extendedPrivateKeyString.should.equal(priv);
Identity._newWallet.getCall(1).args[0].privateKey.toObj().extendedPrivateKeyString.should.equal(priv);
should.not.exist(err);
done();
});
@ -253,7 +253,7 @@ describe('Identity model', function() {
iden.openWallet('dummy', 'xxx', function(err, w) {
should.not.exist(err);
w.store.calledOnce.should.equal(true);
iden.profile.setLastOpenedTs.calledOnce.should.equal(true);
iden.profile.setLastOpenedTs.calledTwice.should.equal(true);
iden.migrateWallet.calledOnce.should.equal(true);
done();
});

View file

@ -19,7 +19,7 @@ describe('Profile model', function() {
};
beforeEach(function() {
storage.getItem = sinon.stub();
storage.setPassphrase = sinon.stub();
storage.set = sinon.stub();
storage.set.yields(null);
storage.get = sinon.stub().yields(null);