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

Unified Diff: extensions/renderer/api_test_base.cc

Issue 2936213002: [Extensions] Don't require() a module for calling a method (Closed)
Patch Set: lazyboy's Created 3 years, 6 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 | « no previous file | extensions/renderer/json_schema_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/renderer/api_test_base.cc
diff --git a/extensions/renderer/api_test_base.cc b/extensions/renderer/api_test_base.cc
index b4f6342f64a11ae9f8e014fd6614ea0a4312df18..9f87585bbcf62de8c070a0f73c43d6d635bf775f 100644
--- a/extensions/renderer/api_test_base.cc
+++ b/extensions/renderer/api_test_base.cc
@@ -222,6 +222,9 @@ void ApiTestEnvironment::RunTestInner(const std::string& test_name,
FAIL() << "Failed to run test \"" << test_name << "\"";
}
};
+
+ ASSERT_FALSE(
+ env()->module_system()->Require("testBody").ToLocalChecked().IsEmpty());
env()->module_system()->CallModuleMethodSafe(
"testBody", test_name, 0, nullptr,
base::Bind(callback, &did_run, quit_closure, test_name));
« no previous file with comments | « no previous file | extensions/renderer/json_schema_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698