refactor readWallet

This commit is contained in:
Matias Alejo Garcia 2014-09-27 16:49:53 -03:00
parent 2bc1945309
commit a446d3775e
1 changed files with 3 additions and 3 deletions

View File

@ -343,8 +343,8 @@ describe('Storage model', function() {
});
});
describe('#readWallet', function() {
it('should read wallet', function(done) {
describe('#getFirst', function() {
it('should read first key', function(done) {
var data = {
'wallet::id1_wallet1': {
a: 'x',
@ -358,7 +358,7 @@ describe('Storage model', function() {
sinon.stub(s, '_read', function(k, cb) {
return cb(data[k]);
});
s.readWallet('id1', function(err, w) {
s.getFirst('wallet::id1', function(err, w) {
should.not.exist(err);
w.should.exist;
w.hasOwnProperty('a').should.be.true;