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

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

Issue 425653002: content: ResourceType cleanup. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: REBASE Created 6 years, 5 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
Index: chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_unittest.cc
diff --git a/chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_unittest.cc b/chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_unittest.cc
index dab3389539f9ad79909a91b957f9386f99b4363e..2da3e037060618ba0557291f1c50be4ebf1df52e 100644
--- a/chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_unittest.cc
+++ b/chrome/browser/extensions/api/declarative_webrequest/webrequest_condition_unittest.cc
@@ -85,7 +85,13 @@ TEST(WebRequestConditionTest, CreateCondition) {
request_data.url_match_ids = matcher.MatchURL(http_url);
EXPECT_EQ(1u, request_data.url_match_ids.size());
content::ResourceRequestInfo::AllocateForTesting(
- &match_request, ResourceType::MAIN_FRAME, NULL, -1, -1, -1, false);
+ &match_request,
+ content::RESOURCE_TYPE_MAIN_FRAME,
+ NULL,
+ -1,
+ -1,
+ -1,
+ false);
EXPECT_TRUE(result->IsFulfilled(request_data));
const GURL https_url("https://www.example.com");
@@ -96,7 +102,13 @@ TEST(WebRequestConditionTest, CreateCondition) {
// Make sure IsFulfilled does not fail because of URL matching.
EXPECT_EQ(1u, request_data.url_match_ids.size());
content::ResourceRequestInfo::AllocateForTesting(
- &wrong_resource_type, ResourceType::SUB_FRAME, NULL, -1, -1, -1, false);
+ &wrong_resource_type,
+ content::RESOURCE_TYPE_SUB_FRAME,
+ NULL,
+ -1,
+ -1,
+ -1,
+ false);
EXPECT_FALSE(result->IsFulfilled(request_data));
}
@@ -136,7 +148,13 @@ TEST(WebRequestConditionTest, CreateConditionFirstPartyForCookies) {
request_data.first_party_url_match_ids = matcher.MatchURL(first_party_url);
EXPECT_EQ(1u, request_data.first_party_url_match_ids.size());
content::ResourceRequestInfo::AllocateForTesting(
- &match_request, ResourceType::MAIN_FRAME, NULL, -1, -1, -1, false);
+ &match_request,
+ content::RESOURCE_TYPE_MAIN_FRAME,
+ NULL,
+ -1,
+ -1,
+ -1,
+ false);
EXPECT_TRUE(result->IsFulfilled(request_data));
}

Powered by Google App Engine
This is Rietveld 408576698