| Index: third_party/WebKit/LayoutTests/fast/css/css-property-setter-getter.html
|
| diff --git a/third_party/WebKit/PerformanceTests/CSS/CSSPropertyUpdateValue.html b/third_party/WebKit/LayoutTests/fast/css/css-property-setter-getter.html
|
| similarity index 79%
|
| copy from third_party/WebKit/PerformanceTests/CSS/CSSPropertyUpdateValue.html
|
| copy to third_party/WebKit/LayoutTests/fast/css/css-property-setter-getter.html
|
| index f64dd90cc642c1639400f3951b55860677f7246d..a84aae77f64d8d03bd113905f8c18ee7036f121f 100644
|
| --- a/third_party/WebKit/PerformanceTests/CSS/CSSPropertyUpdateValue.html
|
| +++ b/third_party/WebKit/LayoutTests/fast/css/css-property-setter-getter.html
|
| @@ -1,11 +1,6 @@
|
| <!DOCTYPE html>
|
| -<html>
|
| -<head>
|
| -<script src="../resources/runner.js"></script>
|
| -</head>
|
| -<body>
|
| +Smoke test for CSS style array index getter and setter. Passes if no crash.
|
| <div id="test"></div>
|
| -</body>
|
| <script>
|
| var div = document.getElementById("test");
|
| var properties = {
|
| @@ -71,13 +66,26 @@ var properties = {
|
| 'webkitTransform' : 'scale3d(0.5, 0.5, 0.5)',
|
| 'wordSpacing' : '40px',
|
| };
|
| -// The first run will just add the properties but it's fine as the first run of the benchmark is always ignored.
|
| -PerfTestRunner.measureRunsPerSecond({
|
| - description: "Measures performance of the CSS style array index setter (elem.style[a] = b).",
|
| - run:function() {
|
| - for (key in properties)
|
| - div.style[key] = properties[key];
|
| - }
|
| -});
|
| +
|
| +if (window.testRunner)
|
| + testRunner.dumpAsText();
|
| +
|
| +for (key in properties) {
|
| + var value = div.style[key];
|
| + div.style[key] = properties[key];
|
| +}
|
| +
|
| +document.body.offsetHeight;
|
| +
|
| +for (key in properties) {
|
| + var value = div.style[key];
|
| + div.style[key] = '';
|
| +}
|
| +
|
| +document.body.offsetHeight;
|
| +
|
| +for (key in properties) {
|
| + var value = div.style[key];
|
| + div.style[key] = properties[key];
|
| +}
|
| </script>
|
| -</html>
|
|
|