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

Unified Diff: extensions/common/matcher/url_matcher_unittest.cc

Issue 16866009: Rewrite scoped_ptr<T>(NULL) to use the default ctor in extensions/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | « extensions/common/matcher/url_matcher_factory.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/common/matcher/url_matcher_unittest.cc
diff --git a/extensions/common/matcher/url_matcher_unittest.cc b/extensions/common/matcher/url_matcher_unittest.cc
index 15a41a16bfeda2d01f2441fdf1887eec7262d15c..1b194ed8b98ea9ae0ebb7d50ffc123a6f149c3a8 100644
--- a/extensions/common/matcher/url_matcher_unittest.cc
+++ b/extensions/common/matcher/url_matcher_unittest.cc
@@ -449,16 +449,18 @@ TEST(URLMatcherConditionSetTest, Matching) {
// Test scheme filters.
scoped_refptr<URLMatcherConditionSet> condition_set2(
- new URLMatcherConditionSet(1, conditions,
- scoped_ptr<URLMatcherSchemeFilter>(
- new URLMatcherSchemeFilter("https")),
- scoped_ptr<URLMatcherPortFilter>(NULL)));
+ new URLMatcherConditionSet(1,
+ conditions,
+ scoped_ptr<URLMatcherSchemeFilter>(
+ new URLMatcherSchemeFilter("https")),
+ scoped_ptr<URLMatcherPortFilter>()));
EXPECT_FALSE(condition_set2->IsMatch(matching_patterns, url1));
scoped_refptr<URLMatcherConditionSet> condition_set3(
- new URLMatcherConditionSet(1, conditions,
- scoped_ptr<URLMatcherSchemeFilter>(
- new URLMatcherSchemeFilter("http")),
- scoped_ptr<URLMatcherPortFilter>(NULL)));
+ new URLMatcherConditionSet(1,
+ conditions,
+ scoped_ptr<URLMatcherSchemeFilter>(
+ new URLMatcherSchemeFilter("http")),
+ scoped_ptr<URLMatcherPortFilter>()));
EXPECT_TRUE(condition_set3->IsMatch(matching_patterns, url1));
// Test port filters.
@@ -466,8 +468,8 @@ TEST(URLMatcherConditionSetTest, Matching) {
ranges.push_back(URLMatcherPortFilter::CreateRange(80));
scoped_ptr<URLMatcherPortFilter> filter(new URLMatcherPortFilter(ranges));
scoped_refptr<URLMatcherConditionSet> condition_set4(
- new URLMatcherConditionSet(1, conditions,
- scoped_ptr<URLMatcherSchemeFilter>(NULL), filter.Pass()));
+ new URLMatcherConditionSet(
+ 1, conditions, scoped_ptr<URLMatcherSchemeFilter>(), filter.Pass()));
EXPECT_TRUE(condition_set4->IsMatch(matching_patterns, url1));
EXPECT_TRUE(condition_set4->IsMatch(matching_patterns, url3));
EXPECT_FALSE(condition_set4->IsMatch(matching_patterns, url4));
« no previous file with comments | « extensions/common/matcher/url_matcher_factory.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698