Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(716)

Side by Side Diff: third_party/WebKit/LayoutTests/payments/resources/payment-request-mock.js

Issue 2456483003: Fix payments layout test timeout. (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/TestExpectations ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * payment-request-mock contains a mock implementation of PaymentRequest. 2 * payment-request-mock contains a mock implementation of PaymentRequest.
3 */ 3 */
4 4
5 "use strict"; 5 "use strict";
6 6
7 let paymentRequestMock = loadMojoModules( 7 let paymentRequestMock = loadMojoModules(
8 'paymentRequestMock', 8 'paymentRequestMock',
9 ['third_party/WebKit/public/platform/modules/payments/payment_request.mojom' , 9 ['components/payments/payment_request.mojom',
10 'mojo/public/js/router', 10 'mojo/public/js/router',
11 ]).then(mojo => { 11 ]).then(mojo => {
12 let [paymentRequest, router] = mojo.modules; 12 let [paymentRequest, router] = mojo.modules;
13 13
14 class PaymentRequestMock { 14 class PaymentRequestMock {
15 constructor(interfaceProvider) { 15 constructor(interfaceProvider) {
16 interfaceProvider.addInterfaceOverrideForTesting( 16 interfaceProvider.addInterfaceOverrideForTesting(
17 paymentRequest.PaymentRequest.name, 17 paymentRequest.PaymentRequest.name,
18 handle => this.connectPaymentRequest_(handle)); 18 handle => this.connectPaymentRequest_(handle));
19 19
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 } 52 }
53 this.client_.onPaymentResponse(new paymentRequest.PaymentResponse(data)); 53 this.client_.onPaymentResponse(new paymentRequest.PaymentResponse(data));
54 } 54 }
55 55
56 onComplete() { 56 onComplete() {
57 this.client_.onComplete(); 57 this.client_.onComplete();
58 } 58 }
59 } 59 }
60 return new PaymentRequestMock(mojo.frameInterfaces); 60 return new PaymentRequestMock(mojo.frameInterfaces);
61 }); 61 });
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/TestExpectations ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698