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

Unified Diff: net/filter/sdch_filter_unittest.cc

Issue 298063006: Make SdchManager per-profile. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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: net/filter/sdch_filter_unittest.cc
diff --git a/net/filter/sdch_filter_unittest.cc b/net/filter/sdch_filter_unittest.cc
index 37f48866707bfece16ba4c183b33f7d3f603d43c..f71f3de67a976181a7dad94ebfc2eb1279f80b90 100644
--- a/net/filter/sdch_filter_unittest.cc
+++ b/net/filter/sdch_filter_unittest.cc
@@ -372,9 +372,9 @@ TEST_F(SdchFilterTest, BasicBadDictionary) {
EXPECT_EQ(0, output_bytes_or_buffer_size);
EXPECT_EQ(Filter::FILTER_ERROR, status);
- EXPECT_FALSE(SdchManager::Global()->IsInSupportedDomain(GURL(url_string)));
- SdchManager::ClearBlacklistings();
- EXPECT_TRUE(SdchManager::Global()->IsInSupportedDomain(GURL(url_string)));
+ EXPECT_FALSE(sdch_manager_->IsInSupportedDomain(GURL(url_string)));
+ sdch_manager_->ClearBlacklistings();
+ EXPECT_TRUE(sdch_manager_->IsInSupportedDomain(GURL(url_string)));
}
TEST_F(SdchFilterTest, DictionaryAddOnce) {
@@ -632,10 +632,10 @@ TEST_F(SdchFilterTest, CrossDomainDictionaryUse) {
filter.get(), &output));
EXPECT_EQ(output.size(), 0u); // No output written.
- EXPECT_TRUE(SdchManager::Global()->IsInSupportedDomain(GURL(url_string)));
- EXPECT_FALSE(SdchManager::Global()->IsInSupportedDomain(wrong_domain_url));
- SdchManager::ClearBlacklistings();
- EXPECT_TRUE(SdchManager::Global()->IsInSupportedDomain(wrong_domain_url));
+ EXPECT_TRUE(sdch_manager_->IsInSupportedDomain(GURL(url_string)));
+ EXPECT_FALSE(sdch_manager_->IsInSupportedDomain(wrong_domain_url));
+ sdch_manager_->ClearBlacklistings();
+ EXPECT_TRUE(sdch_manager_->IsInSupportedDomain(wrong_domain_url));
}
TEST_F(SdchFilterTest, DictionaryPathValidation) {
@@ -683,9 +683,9 @@ TEST_F(SdchFilterTest, DictionaryPathValidation) {
output_block_size, filter.get(), &output));
EXPECT_EQ(output.size(), 0u); // No output written.
- EXPECT_FALSE(SdchManager::Global()->IsInSupportedDomain(GURL(url_string)));
- SdchManager::ClearBlacklistings();
- EXPECT_TRUE(SdchManager::Global()->IsInSupportedDomain(GURL(url_string)));
+ EXPECT_FALSE(sdch_manager_->IsInSupportedDomain(GURL(url_string)));
+ sdch_manager_->ClearBlacklistings();
+ EXPECT_TRUE(sdch_manager_->IsInSupportedDomain(GURL(url_string)));
}
TEST_F(SdchFilterTest, DictionaryPortValidation) {
@@ -746,9 +746,9 @@ TEST_F(SdchFilterTest, DictionaryPortValidation) {
output_block_size, filter.get(), &output));
EXPECT_EQ(output.size(), 0u); // No output written.
- EXPECT_FALSE(SdchManager::Global()->IsInSupportedDomain(GURL(url_string)));
- SdchManager::ClearBlacklistings();
- EXPECT_TRUE(SdchManager::Global()->IsInSupportedDomain(GURL(url_string)));
+ EXPECT_FALSE(sdch_manager_->IsInSupportedDomain(GURL(url_string)));
+ sdch_manager_->ClearBlacklistings();
+ EXPECT_TRUE(sdch_manager_->IsInSupportedDomain(GURL(url_string)));
}
//------------------------------------------------------------------------------

Powered by Google App Engine
This is Rietveld 408576698