paypal-checkout
Advanced tools
Comparing version 4.0.31 to 4.0.32
@@ -21,4 +21,3 @@ var argv = require('yargs').argv; | ||
{ pattern: 'test/test.js', included: true, served: true }, | ||
{ pattern: 'test/*.js', included: false, served: true }, | ||
{ pattern: 'test/*.htm', included: false, served: true }, | ||
{ pattern: 'test/**/*', included: false, served: true } | ||
], | ||
@@ -105,6 +104,3 @@ | ||
'test/test.js': ['webpack'], | ||
'test/checkout.js': ['webpack'], | ||
'test/button.js': ['webpack'], | ||
'test/fallback.js': ['webpack'], | ||
'test/bridge.js': ['webpack'], | ||
'test/windows/**/*.js': ['webpack'], | ||
'src/**/*.js': ['coverage', 'sourcemap'] | ||
@@ -111,0 +107,0 @@ }, |
{ | ||
"name": "paypal-checkout", | ||
"version": "4.0.31", | ||
"version": "4.0.32", | ||
"description": "Checkout components, for integratng checkout products.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -101,3 +101,3 @@ | ||
production: `/checkoutnow`, | ||
test: `/base/test/checkout.htm?checkouturl=true` | ||
test: `/base/test/windows/checkout/index.htm?checkouturl=true` | ||
}, | ||
@@ -110,3 +110,3 @@ | ||
production: `/agreements/approve`, | ||
test: `/base/test/checkout.htm?billingurl=true` | ||
test: `/base/test/windows/checkout/index.htm?billingurl=true` | ||
}, | ||
@@ -119,3 +119,3 @@ | ||
production: `/webapps/hermes/button`, | ||
test: `/base/test/button.htm` | ||
test: `/base/test/windows/button/index.htm` | ||
}, | ||
@@ -128,3 +128,3 @@ | ||
production: `/webapps/hermes/component-meta`, | ||
test: `/base/test/bridge.htm` | ||
test: `/base/test/windows/bridge/index.htm` | ||
}, | ||
@@ -131,0 +131,0 @@ |
@@ -11,2 +11,3 @@ | ||
export { setup } from '../setup'; | ||
export { config } from '../config'; | ||
export { request, isEligible } from '../lib'; | ||
@@ -13,0 +14,0 @@ |
@@ -11,2 +11,3 @@ | ||
export { setup } from '../setup'; | ||
export { config } from '../config'; | ||
export { request, isEligible } from '../lib'; | ||
@@ -13,0 +14,0 @@ |
@@ -521,3 +521,30 @@ | ||
if (flow === 'lightbox') { | ||
it('should render a button into a container and click on the button, popout, then complete the payment', (done) => { | ||
return paypal.Button.render({ | ||
testAction: 'popout', | ||
payment() { | ||
return generateECToken(); | ||
}, | ||
onAuthorize() { | ||
return done(); | ||
}, | ||
onCancel() { | ||
return done(new Error('Expected onCancel to not be called')); | ||
} | ||
}, '#testContainer').then(button => { | ||
button.window.paypal.Checkout.contexts.lightbox = (flow === 'lightbox'); | ||
button.window.document.querySelector('button').click(); | ||
}); | ||
}); | ||
} | ||
}); | ||
} |
@@ -452,3 +452,26 @@ | ||
if (flow === 'lightbox') { | ||
it('should render checkout, popout, then complete the payment', (done) => { | ||
return paypal.Checkout.render({ | ||
testAction: 'popout', | ||
payment() { | ||
return generateECToken(); | ||
}, | ||
onAuthorize() { | ||
return done(); | ||
}, | ||
onCancel() { | ||
return done(new Error('Expected onCancel to not be called')); | ||
} | ||
}); | ||
}); | ||
} | ||
}); | ||
} |
@@ -57,4 +57,4 @@ | ||
export const CHILD_URI = '/base/test/checkout.htm'; | ||
export const CHILD_REDIRECT_URI = '/base/test/childRedirect.htm'; | ||
export const CHILD_URI = '/base/test/windows/checkout/index.htm'; | ||
export const CHILD_REDIRECT_URI = '/base/test/windows/redirect/index.htm'; | ||
@@ -61,0 +61,0 @@ export const IE8_USER_AGENT = 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0)'; |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
1985326
26830