Merge pull request #646 from ryanxcharles/bug/fix-getEncryptedObj-test
fix getEncryptedObj test
This commit is contained in:
commit
fd7eaca46a
2 changed files with 4 additions and 5 deletions
|
|
@ -12,12 +12,11 @@
|
|||
<script src="../node_modules/chai/chai.js"></script>
|
||||
<script src="../lib/crypto-js/rollups/aes.js"></script>
|
||||
<script>mocha.setup('bdd')</script>
|
||||
<script src="../lib/bitcore.js"></script>
|
||||
<script src="../lib/bitcore/browser/bundle.js"></script>
|
||||
<script src="../js/copayBundle.js"></script>
|
||||
<script>
|
||||
var copay = require('copay');
|
||||
</script>
|
||||
<script src="test.API.js"></script>
|
||||
<script src="test.blockchain.Insight.js"></script>
|
||||
<script src="test.performance.js"></script>
|
||||
<script src="test.PrivateKey.js"></script>
|
||||
|
|
|
|||
|
|
@ -46,13 +46,13 @@ if (typeof process === 'undefined' || !process.version) {
|
|||
});
|
||||
});
|
||||
|
||||
describe('#getEncryptedObj', function() {
|
||||
it('should encrypt the wallet', function() {
|
||||
describe('#export', function() {
|
||||
it('should export the encrypted wallet', function() {
|
||||
localStorage.clear();
|
||||
var storage = new LocalEncrypted({password: 'password'});
|
||||
storage.set('walletId', 'test', 'testval');
|
||||
var obj = {test:'testval'};
|
||||
var encrypted = storage.getEncryptedObj('walletId');
|
||||
var encrypted = storage.export(obj);
|
||||
encrypted.length.should.be.greaterThan(10);
|
||||
//encrypted.slice(0,6).should.equal("53616c");
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue