mirror of https://github.com/BTCPrivate/copay.git
skip PayPro test in browser, they break in travis
This commit is contained in:
parent
560465b6c1
commit
9047f4f30b
|
@ -3,8 +3,7 @@
|
|||
var chai = chai || require('chai');
|
||||
var should = chai.should();
|
||||
var sinon = require('sinon');
|
||||
var is_browser = typeof process == 'undefined'
|
||||
|| typeof process.versions === 'undefined';
|
||||
var is_browser = typeof process == 'undefined' || typeof process.versions === 'undefined';
|
||||
if (is_browser) {
|
||||
var copay = require('copay'); //browser
|
||||
} else {
|
||||
|
@ -42,6 +41,7 @@ var getNewEpk = function() {
|
|||
};
|
||||
|
||||
describe('PayPro (in Wallet) model', function() {
|
||||
if (!is_browser) {
|
||||
var createW = function(N, conf) {
|
||||
var c = JSON.parse(JSON.stringify(conf || walletConfig));
|
||||
if (!N) N = c.totalCopayers;
|
||||
|
@ -165,8 +165,7 @@ describe('PayPro (in Wallet) model', function() {
|
|||
var req = {
|
||||
headers: {
|
||||
'Host': 'localhost:8080',
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE
|
||||
+ ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE + ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Content-Type': 'application/octet-stream',
|
||||
'Content-Length': '0'
|
||||
},
|
||||
|
@ -345,8 +344,7 @@ describe('PayPro (in Wallet) model', function() {
|
|||
var req = {
|
||||
headers: {
|
||||
'Host': 'localhost:8080',
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE
|
||||
+ ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE + ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Content-Type': PayPro.PAYMENT_CONTENT_TYPE,
|
||||
'Content-Length': pay.length + ''
|
||||
},
|
||||
|
@ -414,8 +412,7 @@ describe('PayPro (in Wallet) model', function() {
|
|||
var req = {
|
||||
headers: {
|
||||
'Host': 'localhost:8080',
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE
|
||||
+ ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE + ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Content-Type': 'application/octet-stream',
|
||||
'Content-Length': '0'
|
||||
},
|
||||
|
@ -594,8 +591,7 @@ describe('PayPro (in Wallet) model', function() {
|
|||
var req = {
|
||||
headers: {
|
||||
'Host': 'localhost:8080',
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE
|
||||
+ ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Accept': PayPro.PAYMENT_REQUEST_CONTENT_TYPE + ', ' + PayPro.PAYMENT_ACK_CONTENT_TYPE,
|
||||
'Content-Type': PayPro.PAYMENT_CONTENT_TYPE,
|
||||
'Content-Length': pay.length + ''
|
||||
},
|
||||
|
@ -718,7 +714,9 @@ describe('PayPro (in Wallet) model', function() {
|
|||
if (w.isShared()) {
|
||||
return done();
|
||||
} else {
|
||||
w.sendPaymentTx(ntxid, { memo: memo }, function(txid, merchantData) {
|
||||
w.sendPaymentTx(ntxid, {
|
||||
memo: memo
|
||||
}, function(txid, merchantData) {
|
||||
should.exist(txid);
|
||||
should.exist(merchantData);
|
||||
return done();
|
||||
|
@ -892,4 +890,5 @@ describe('PayPro (in Wallet) model', function() {
|
|||
return done();
|
||||
});
|
||||
});
|
||||
}
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue