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

Unified Diff: test/browser/elemHideEmulation.js

Issue 29486558: Issue 5404 - :-abp-properties() nested within :-abp-has() should work if the relevant selector refe… (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore/
Patch Set: Created July 11, 2017, 10:20 a.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/elemHideEmulation.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/browser/elemHideEmulation.js
===================================================================
--- a/test/browser/elemHideEmulation.js
+++ b/test/browser/elemHideEmulation.js
@@ -384,25 +384,34 @@ function runTestPseudoClassHasSelectorWi
}).catch(unexpectedError.bind(test)).then(() => test.done());
}
exports.testPseudoClassHasSelectorWithHasAndWithSuffixSibling = function(test)
{
runTestPseudoClassHasSelectorWithHasAndWithSuffixSibling(test, "div:-abp-has(:-abp-has(div.inside)) + div > div");
};
-exports.testPseudoClassHasSelectorWithHasAndWithSuffixSibling2 = function(test)
-{
- runTestPseudoClassHasSelectorWithHasAndWithSuffixSibling(test, "div:-abp-has(:-abp-has(> div.inside)) + div > div");
-};
-
hub 2017/07/11 17:19:34 you are removing this test because it fails, but :
exports.testPseudoClassHasSelectorWithPropSelector = function(test)
{
let parent = createElementWithStyle("{}");
let child = createElementWithStyle("{background-color: #000}", parent);
applyElemHideEmulation(
["div:-abp-has(:-abp-properties(background-color: rgb(0, 0, 0)))"]
).then(() =>
{
expectVisible(test, child);
expectHidden(test, parent);
}).catch(unexpectedError.bind(test)).then(() => test.done());
};
+
+exports.testPseudoClassHasSelectorWithPropSelector2 = function(test)
+{
+ let parent = createElementWithStyle("{}");
+ let child = createElementWithStyle("{}", parent);
+ insertStyleRule("body #" + parent.id + " > div { background-color: #000}");
+ applyElemHideEmulation(
+ ["div:-abp-has(:-abp-properties(background-color: rgb(0, 0, 0)))"]
+ ).then(() =>
+ {
+ expectVisible(test, child);
+ expectHidden(test, parent);
+ }).catch(unexpectedError.bind(test)).then(() => test.done());
+};
« no previous file with comments | « chrome/content/elemHideEmulation.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld