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

Unified Diff: PerformanceTests/CSS/AttributeDescendantSelector.html

Issue 199543004: Add a performance test for attribute descendant selectors. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 9 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: PerformanceTests/CSS/AttributeDescendantSelector.html
diff --git a/PerformanceTests/CSS/ClassDescendantSelector.html b/PerformanceTests/CSS/AttributeDescendantSelector.html
similarity index 88%
copy from PerformanceTests/CSS/ClassDescendantSelector.html
copy to PerformanceTests/CSS/AttributeDescendantSelector.html
index 553d7fbae7a8984436029b2edd1b517b5849b340..baf3ec036af135f4f8ff1e3e7ac37c45ab452cfe 100644
--- a/PerformanceTests/CSS/ClassDescendantSelector.html
+++ b/PerformanceTests/CSS/AttributeDescendantSelector.html
@@ -3,7 +3,7 @@
<head>
<script src="../resources/runner.js"></script>
<style>
- .root .child {}
+ [attr=root] [attr=child] {}
</style>
</head>
<body>
@@ -34,13 +34,13 @@ var root = document.querySelector("#root");
makeTree(root, 6, 5, "child");
var child = document.querySelector("#child012341");
-child.className = "child";
+child.setAttribute("attr", "child");
var runFunction = function()
{
root.offsetHeight; // force recalc style
- root.className = "root";
+ root.setAttribute("attr" , "root");
root.offsetHeight;
- root.className = "";
+ root.removeAttribute("attr");
}
PerfTestRunner.measureRunsPerSecond({run: runFunction});
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698