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

Unified Diff: extensions/browser/api/declarative_webrequest/webrequest_condition_unittest.cc

Issue 624073002: Add is_main_frame and parent_is_main_frame to ResourceRequestInfo::AllocateForTesting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix compile extensions_unittests Created 6 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
« no previous file with comments | « extensions/browser/api/declarative_webrequest/webrequest_condition_attribute_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/browser/api/declarative_webrequest/webrequest_condition_unittest.cc
diff --git a/extensions/browser/api/declarative_webrequest/webrequest_condition_unittest.cc b/extensions/browser/api/declarative_webrequest/webrequest_condition_unittest.cc
index 64a9bc8a8fab2fc6e1a63f8104fc3b84f55b7e6f..12d14bd1da1ae639b6242763a2e2d5aa2e6da6ca 100644
--- a/extensions/browser/api/declarative_webrequest/webrequest_condition_unittest.cc
+++ b/extensions/browser/api/declarative_webrequest/webrequest_condition_unittest.cc
@@ -89,11 +89,13 @@ TEST(WebRequestConditionTest, CreateCondition) {
content::ResourceRequestInfo::AllocateForTesting(
match_request.get(),
content::RESOURCE_TYPE_MAIN_FRAME,
- NULL,
- -1,
- -1,
- -1,
- false);
+ NULL, // context
+ -1, // render_process_id
+ -1, // render_view_id
+ -1, // render_frame_id
+ true, // is_main_frame
+ false, // parent_is_main_frame
+ false); // is_async
EXPECT_TRUE(result->IsFulfilled(request_data));
const GURL https_url("https://www.example.com");
@@ -106,11 +108,13 @@ TEST(WebRequestConditionTest, CreateCondition) {
content::ResourceRequestInfo::AllocateForTesting(
wrong_resource_type.get(),
content::RESOURCE_TYPE_SUB_FRAME,
- NULL,
- -1,
- -1,
- -1,
- false);
+ NULL, // context
+ -1, // render_process_id
+ -1, // render_view_id
+ -1, // render_frame_id
+ false, // is_main_frame
+ false, // parent_is_main_frame
+ false); // is_async
EXPECT_FALSE(result->IsFulfilled(request_data));
}
@@ -152,11 +156,13 @@ TEST(WebRequestConditionTest, CreateConditionFirstPartyForCookies) {
content::ResourceRequestInfo::AllocateForTesting(
match_request.get(),
content::RESOURCE_TYPE_MAIN_FRAME,
- NULL,
- -1,
- -1,
- -1,
- false);
+ NULL, // context
+ -1, // render_process_id
+ -1, // render_view_id
+ -1, // render_frame_id
+ true, // is_main_frame
+ false, // parent_is_main_frame
+ false); // is_async
EXPECT_TRUE(result->IsFulfilled(request_data));
}
« no previous file with comments | « extensions/browser/api/declarative_webrequest/webrequest_condition_attribute_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698