Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: chrome/content/tests/matcher.js

Issue 5971196453584896: Issue 2503 - Inconsistent behavior: $document flag implied for exception rules with protocol includ… (Closed)
Patch Set: Created May 18, 2015, 5:51 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/content/tests/filterClasses.js ('k') | chrome/content/tests/regexpFilters_matching.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/content/tests/matcher.js
===================================================================
--- a/chrome/content/tests/matcher.js
+++ b/chrome/content/tests/matcher.js
@@ -162,35 +162,35 @@
checkMatch(["abc$sitekey=foo-publickey,domain=foo.com", "abc$sitekey=bar-publickey,domain=bar.com"], "http://abc/def", "IMAGE", "bar.com", false, "bar-publickey", "abc$sitekey=bar-publickey,domain=bar.com");
});
test("Result cache checks", function()
{
let matcher = new CombinedMatcher();
matcher.add(Filter.fromText("abc$image"));
matcher.add(Filter.fromText("abc$script"));
- matcher.add(Filter.fromText("abc$~image,~script,~document"));
+ matcher.add(Filter.fromText("abc$~image,~script,~media"));
matcher.add(Filter.fromText("cba$third-party"));
matcher.add(Filter.fromText("cba$~third-party,~script"));
matcher.add(Filter.fromText("http://def$image"));
matcher.add(Filter.fromText("http://def$script"));
- matcher.add(Filter.fromText("http://def$~image,~script,~document"));
+ matcher.add(Filter.fromText("http://def$~image,~script,~media"));
matcher.add(Filter.fromText("http://fed$third-party"));
matcher.add(Filter.fromText("http://fed$~third-party,~script"));
cacheCheck(matcher, "http://abc", "IMAGE", null, false, "abc$image");
cacheCheck(matcher, "http://abc", "SCRIPT", null, false, "abc$script");
- cacheCheck(matcher, "http://abc", "OTHER", null, false, "abc$~image,~script,~document");
+ cacheCheck(matcher, "http://abc", "OTHER", null, false, "abc$~image,~script,~media");
cacheCheck(matcher, "http://cba", "IMAGE", null, false, "cba$~third-party,~script");
cacheCheck(matcher, "http://cba", "IMAGE", null, true, "cba$third-party");
cacheCheck(matcher, "http://def", "IMAGE", null, false, "http://def$image");
cacheCheck(matcher, "http://def", "SCRIPT", null, false, "http://def$script");
- cacheCheck(matcher, "http://def", "OTHER", null, false, "http://def$~image,~script,~document");
+ cacheCheck(matcher, "http://def", "OTHER", null, false, "http://def$~image,~script,~media");
cacheCheck(matcher, "http://fed", "IMAGE", null, false, "http://fed$~third-party,~script");
cacheCheck(matcher, "http://fed", "IMAGE", null, true, "http://fed$third-party");
- cacheCheck(matcher, "http://abc_cba", "DOCUMENT", null, false, "cba$~third-party,~script");
- cacheCheck(matcher, "http://abc_cba", "DOCUMENT", null, true, "cba$third-party");
+ cacheCheck(matcher, "http://abc_cba", "MEDIA", null, false, "cba$~third-party,~script");
+ cacheCheck(matcher, "http://abc_cba", "MEDIA", null, true, "cba$third-party");
cacheCheck(matcher, "http://abc_cba", "SCRIPT", null, false, "abc$script");
- cacheCheck(matcher, "http://def?http://fed", "DOCUMENT", null, false, "http://fed$~third-party,~script");
- cacheCheck(matcher, "http://def?http://fed", "DOCUMENT", null, true, "http://fed$third-party");
+ cacheCheck(matcher, "http://def?http://fed", "MEDIA", null, false, "http://fed$~third-party,~script");
+ cacheCheck(matcher, "http://def?http://fed", "MEDIA", null, true, "http://fed$third-party");
cacheCheck(matcher, "http://def?http://fed", "SCRIPT", null, false, "http://def$script");
});
})();
« no previous file with comments | « chrome/content/tests/filterClasses.js ('k') | chrome/content/tests/regexpFilters_matching.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld