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

Unified Diff: third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp

Issue 2477883002: [Web Payments] Mojom namespace blink -> payments (Closed)
Patch Set: Fix WebKit tests 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
diff --git a/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp b/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
index eff21605a3854d2b2454f68a731d32a57bd52fe0..7d2aa270390d400d93a8a6fcf9dfa653570f3afe 100644
--- a/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
+++ b/third_party/WebKit/Source/modules/payments/PaymentRequestTest.cpp
@@ -314,8 +314,8 @@ TEST(PaymentRequestTest, RejectShowPromiseOnInvalidShippingAddress) {
request->show(scope.getScriptState())
.then(funcs.expectNoCall(), funcs.expectCall());
- static_cast<mojom::blink::PaymentRequestClient*>(request)
- ->OnShippingAddressChange(mojom::blink::PaymentAddress::New());
+ static_cast<payments::mojom::blink::PaymentRequestClient*>(request)
+ ->OnShippingAddressChange(payments::mojom::blink::PaymentAddress::New());
}
TEST(PaymentRequestTest, OnShippingOptionChange) {
@@ -330,7 +330,7 @@ TEST(PaymentRequestTest, OnShippingOptionChange) {
request->show(scope.getScriptState())
.then(funcs.expectNoCall(), funcs.expectNoCall());
- static_cast<mojom::blink::PaymentRequestClient*>(request)
+ static_cast<payments::mojom::blink::PaymentRequestClient*>(request)
->OnShippingOptionChange("standardShipping");
}
@@ -358,7 +358,8 @@ TEST(PaymentRequestTest, CannotShowAfterAborted) {
EXPECT_FALSE(scope.getExceptionState().hadException());
request->show(scope.getScriptState());
request->abort(scope.getScriptState());
- static_cast<mojom::blink::PaymentRequestClient*>(request)->OnAbort(true);
+ static_cast<payments::mojom::blink::PaymentRequestClient*>(request)->OnAbort(
+ true);
request->show(scope.getScriptState())
.then(funcs.expectNoCall(), funcs.expectCall());
@@ -377,8 +378,8 @@ TEST(PaymentRequestTest, RejectShowPromiseOnErrorPaymentMethodNotSupported) {
request->show(scope.getScriptState())
.then(funcs.expectNoCall(), funcs.expectCall(&errorMessage));
- static_cast<mojom::blink::PaymentRequestClient*>(request)->OnError(
- mojom::blink::PaymentErrorReason::NOT_SUPPORTED);
+ static_cast<payments::mojom::blink::PaymentRequestClient*>(request)->OnError(
+ payments::mojom::blink::PaymentErrorReason::NOT_SUPPORTED);
v8::MicrotasksScope::PerformCheckpoint(scope.getScriptState()->isolate());
EXPECT_EQ("NotSupportedError: The payment method is not supported",
@@ -398,8 +399,8 @@ TEST(PaymentRequestTest, RejectShowPromiseOnErrorCancelled) {
request->show(scope.getScriptState())
.then(funcs.expectNoCall(), funcs.expectCall(&errorMessage));
- static_cast<mojom::blink::PaymentRequestClient*>(request)->OnError(
- mojom::blink::PaymentErrorReason::USER_CANCEL);
+ static_cast<payments::mojom::blink::PaymentRequestClient*>(request)->OnError(
+ payments::mojom::blink::PaymentErrorReason::USER_CANCEL);
v8::MicrotasksScope::PerformCheckpoint(scope.getScriptState()->isolate());
EXPECT_EQ("Request cancelled", errorMessage);
@@ -434,8 +435,8 @@ TEST(PaymentRequestTest, IgnoreUpdatePaymentDetailsAfterShowPromiseResolved) {
EXPECT_FALSE(scope.getExceptionState().hadException());
request->show(scope.getScriptState())
.then(funcs.expectCall(), funcs.expectNoCall());
- static_cast<mojom::blink::PaymentRequestClient*>(request)->OnPaymentResponse(
- buildPaymentResponseForTest());
+ static_cast<payments::mojom::blink::PaymentRequestClient*>(request)
+ ->OnPaymentResponse(buildPaymentResponseForTest());
request->onUpdatePaymentDetails(
ScriptValue::from(scope.getScriptState(), "foo"));

Powered by Google App Engine
This is Rietveld 408576698