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

Unified Diff: third_party/WebKit/LayoutTests/fast/xpath/xpath-other-nodeset-result-should-mark-its-nodeset.html

Issue 1972943002: Modifies few gc related layout tests to work with ignition. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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: third_party/WebKit/LayoutTests/fast/xpath/xpath-other-nodeset-result-should-mark-its-nodeset.html
diff --git a/third_party/WebKit/LayoutTests/fast/xpath/xpath-other-nodeset-result-should-mark-its-nodeset.html b/third_party/WebKit/LayoutTests/fast/xpath/xpath-other-nodeset-result-should-mark-its-nodeset.html
index 91bb5968fd134f6a41f4f8f7c5dda77a055c280d..107826627ee9a3ae2d11a8de0023ee3337e87391 100644
--- a/third_party/WebKit/LayoutTests/fast/xpath/xpath-other-nodeset-result-should-mark-its-nodeset.html
+++ b/third_party/WebKit/LayoutTests/fast/xpath/xpath-other-nodeset-result-should-mark-its-nodeset.html
@@ -20,9 +20,16 @@
function test(type)
{
- document.getElementsByTagName("span")[0].foo = "PASS";
- var result = document.evaluate("//span", document.documentElement, null, type, null);
- document.body.removeChild(document.getElementsByTagName("span")[0]);
+ var result;
+ function initialize() {
+ document.getElementsByTagName("span")[0].foo = "PASS";
+ result = document.evaluate("//span", document.documentElement, null, type, null);
+ document.body.removeChild(document.getElementsByTagName("span")[0]);
+ }
+
+ // Perform all assignments in a function to avoid references to objects
+ // in dead registers when using ignition (chromium:595672)
+ initialize();
gc();
var console = document.getElementById("console");
console.appendChild(document.createTextNode(result.singleNodeValue.foo));

Powered by Google App Engine
This is Rietveld 408576698