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

Unified Diff: LayoutTests/fast/css/attribute-selector-case-insensitive.html

Issue 330043003: Add support for case-insensitive attribute value selectors (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Make union w/ m_attributeFlags and nth-state; Return enum type. Created 6 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
Index: LayoutTests/fast/css/attribute-selector-case-insensitive.html
diff --git a/LayoutTests/fast/css/attribute-selector-case-insensitive.html b/LayoutTests/fast/css/attribute-selector-case-insensitive.html
new file mode 100644
index 0000000000000000000000000000000000000000..4ac74b80d206643987d2e6a8f9c99699fdb16a38
--- /dev/null
+++ b/LayoutTests/fast/css/attribute-selector-case-insensitive.html
@@ -0,0 +1,27 @@
+<!DOCTYPE html>
+
+<style type="text/css">
+ div { border: 2px solid red; }
+ div[attr1="LOWER"] { border-top-color: yellow }
+ div[attr1="lower"] { border-top-color: green }
+ div[attr2="upper"] { border-right-color: yellow }
+ div[attr2="UPPER"] { border-right-color: green }
+ div[attr3="lower" i] { border-bottom-color: green }
+ div[attr4="UPPER" i] { border-left-color: green }
+</style>
+
+<div id="element" attr1="lower" attr2="UPPER" attr3="LOWER" attr4="upper">
+ PASS if this element's border is all green, not red.
+</div>
+
+<script src="../../resources/js-test.js"></script>
+<script>
+ if (window.testRunner)
+ testRunner.dumpAsText();
+
+ var element = document.getElementById("element");
+ shouldBe("window.getComputedStyle(element).borderTopColor", "'rgb(0, 128, 0)'");
+ shouldBe("window.getComputedStyle(element).borderRightColor", "'rgb(0, 128, 0)'");
+ shouldBe("window.getComputedStyle(element).borderBottomColor", "'rgb(0, 128, 0)'");
+ shouldBe("window.getComputedStyle(element).borderLeftColor", "'rgb(0, 128, 0)'");
+</script>

Powered by Google App Engine
This is Rietveld 408576698