Chromium Code Reviews| Index: third_party/WebKit/Source/modules/payments/PaymentResponseTest.cpp |
| diff --git a/third_party/WebKit/Source/modules/payments/PaymentResponseTest.cpp b/third_party/WebKit/Source/modules/payments/PaymentResponseTest.cpp |
| index 35da551475c3540bd99e0d0fd453386bf6539029..a3a215aa8a57d23314bd1e8b64f2cb29bc6f1504 100644 |
| --- a/third_party/WebKit/Source/modules/payments/PaymentResponseTest.cpp |
| +++ b/third_party/WebKit/Source/modules/payments/PaymentResponseTest.cpp |
| @@ -69,6 +69,20 @@ TEST(PaymentResponseTest, DataCopiedOver) |
| EXPECT_EQ(123, transactionId.v8Value().As<v8::Number>()->Value()); |
| } |
| +TEST(PaymentResponseTest, PaymentResponseDetailsJSONObject) |
| +{ |
| + V8TestingScope scope; |
| + mojom::blink::PaymentResponsePtr input = buildPaymentResponseForTest(); |
| + input->stringified_details = "transactionId"; |
| + MockPaymentCompleter* completeCallback = new MockPaymentCompleter; |
| + |
|
please use gerrit instead
2016/07/22 16:58:54
Remove this empty line. A typical test has three s
|
| + PaymentResponse output(std::move(input), completeCallback); |
| + |
| + ScriptValue details = output.details(scope.getScriptState(), scope.getExceptionState()); |
| + |
| + ASSERT_TRUE(scope.getExceptionState().hadException()); |
| +} |
| + |
| TEST(PaymentResponseTest, CompleteCalledWithSuccess) |
| { |
| V8TestingScope scope; |