make mocha browser tests all run with no console errors

...except Wallet and WalletFactory.
This commit is contained in:
Ryan X. Charles 2014-06-15 20:55:23 -07:00
commit f7e34acae8
14 changed files with 85 additions and 39 deletions

View file

@ -5,7 +5,11 @@ var should = chai.should();
var bitcore = bitcore || require('bitcore');
var Address = bitcore.Address;
var buffertools = bitcore.buffertools;
var copay = copay || require('../copay');
try {
var copay = require('copay'); //browser
} catch (e) {
var copay = require('../copay'); //node
}
var PublicKeyRing = copay.PublicKeyRing;
var AddressIndex = copay.AddressIndex;