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

Unified Diff: gin/wrappable_unittest.cc

Issue 681713002: Update from chromium https://crrev.com/301315 (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 6 years, 2 months 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
« no previous file with comments | « gin/function_template.h.pump ('k') | gpu/command_buffer/service/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gin/wrappable_unittest.cc
diff --git a/gin/wrappable_unittest.cc b/gin/wrappable_unittest.cc
index 8dbaf30132536509ec0b746ca00ce5c4b65f399b..ef0dce4cdc175277b0ad4839f319e2fabd13f97b 100644
--- a/gin/wrappable_unittest.cc
+++ b/gin/wrappable_unittest.cc
@@ -94,11 +94,11 @@ class MyCallableObject : public Wrappable<MyCallableObject> {
~MyCallableObject() override {}
- void Call(int val, const gin::Arguments& arguments) {
+ void Call(int val1, int val2, int val3, const gin::Arguments& arguments) {
if (arguments.IsConstructCall())
arguments.ThrowTypeError("Cannot be called as constructor.");
else
- result_ = val;
+ result_ = val1;
}
int result_;
@@ -230,7 +230,7 @@ TEST_F(WrappableTest, CallAsFunction) {
EXPECT_EQ(0, object->result());
v8::Handle<v8::String> source = StringToV8(isolate,
"(function(obj) {"
- "obj(42);"
+ "obj(42, 2, 5);"
"})");
gin::TryCatch try_catch;
v8::Handle<v8::Script> script = v8::Script::Compile(source);
@@ -253,7 +253,7 @@ TEST_F(WrappableTest, CallAsConstructor) {
EXPECT_EQ(0, object->result());
v8::Handle<v8::String> source = StringToV8(isolate,
"(function(obj) {"
- "new obj(42);"
+ "new obj(42, 2, 5);"
"})");
gin::TryCatch try_catch;
v8::Handle<v8::Script> script = v8::Script::Compile(source);
« no previous file with comments | « gin/function_template.h.pump ('k') | gpu/command_buffer/service/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698