mirror of https://github.com/BTCPrivate/copay.git
fix tests
This commit is contained in:
parent
22ed51d047
commit
399ab1a75f
|
@ -150,7 +150,7 @@ angular.module('copayApp.services')
|
||||||
root.profile.setChecked(platformInfo.ua, credentials.walletId);
|
root.profile.setChecked(platformInfo.ua, credentials.walletId);
|
||||||
|
|
||||||
return cb(null, root.bindWalletClient(client));
|
return cb(null, root.bindWalletClient(client));
|
||||||
}, 1);
|
}, skipKeyValidation ? 50 : 0);
|
||||||
};
|
};
|
||||||
|
|
||||||
root.bindProfile = function(profile, cb) {
|
root.bindProfile = function(profile, cb) {
|
||||||
|
@ -164,6 +164,8 @@ angular.module('copayApp.services')
|
||||||
var l = root.profile.credentials.length;
|
var l = root.profile.credentials.length;
|
||||||
var i = 0, totalBound = 0;
|
var i = 0, totalBound = 0;
|
||||||
|
|
||||||
|
if (!l) return cb();
|
||||||
|
|
||||||
lodash.each(root.profile.credentials, function(credentials) {
|
lodash.each(root.profile.credentials, function(credentials) {
|
||||||
root.bindWallet(credentials, function(err, bound) {
|
root.bindWallet(credentials, function(err, bound) {
|
||||||
i++;
|
i++;
|
||||||
|
@ -311,6 +313,7 @@ angular.module('copayApp.services')
|
||||||
// Creates a wallet on BWC/BWS
|
// Creates a wallet on BWC/BWS
|
||||||
var doCreateWallet = function(opts, cb) {
|
var doCreateWallet = function(opts, cb) {
|
||||||
$log.debug('Creating Wallet:', opts);
|
$log.debug('Creating Wallet:', opts);
|
||||||
|
$timeout(function() {
|
||||||
seedWallet(opts, function(err, walletClient) {
|
seedWallet(opts, function(err, walletClient) {
|
||||||
if (err) return cb(err);
|
if (err) return cb(err);
|
||||||
|
|
||||||
|
@ -326,6 +329,7 @@ angular.module('copayApp.services')
|
||||||
return cb(null, walletClient, secret);
|
return cb(null, walletClient, secret);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
}, 5);
|
||||||
};
|
};
|
||||||
|
|
||||||
// Creates the default Copay profile and its wallet
|
// Creates the default Copay profile and its wallet
|
||||||
|
@ -634,7 +638,6 @@ angular.module('copayApp.services')
|
||||||
var defaults = configService.getDefaults();
|
var defaults = configService.getDefaults();
|
||||||
|
|
||||||
configService.get(function(err) {
|
configService.get(function(err) {
|
||||||
|
|
||||||
root.createDefaultProfile(opts, function(err, p) {
|
root.createDefaultProfile(opts, function(err, p) {
|
||||||
if (err) return cb(err);
|
if (err) return cb(err);
|
||||||
|
|
||||||
|
|
|
@ -221,7 +221,6 @@ mocks.init = function(fixtures, controllerName, opts, done) {
|
||||||
done();
|
done();
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
_profileService_.create({
|
_profileService_.create({
|
||||||
noWallet: true
|
noWallet: true
|
||||||
}, function(err) {
|
}, function(err) {
|
||||||
|
|
Loading…
Reference in New Issue