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

Unified Diff: tools/perf/page_sets/tough_ad_cases.py

Issue 2379073002: perf: Speculative fix for tough_webgl_ad_cases (Closed)
Patch Set: Cleanup Created 4 years, 3 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: tools/perf/page_sets/tough_ad_cases.py
diff --git a/tools/perf/page_sets/tough_ad_cases.py b/tools/perf/page_sets/tough_ad_cases.py
index f076f6a4f5f2ef6fd9accbba9e543f5b248d6d20..41d79d6299dde1c8c1f27159227b298f1337be0d 100644
--- a/tools/perf/page_sets/tough_ad_cases.py
+++ b/tools/perf/page_sets/tough_ad_cases.py
@@ -25,6 +25,8 @@ class SwiffyPage(page_module.Page):
'var meta = document.createElement("meta");'
'meta.name = "viewport";'
'meta.content = "width=device-width";'
+ 'if (!document.getElementsByTagName("head"))'
+ ' document.body.appendChild(document.createElement("head"));'
'document.getElementsByTagName("head")[0].appendChild(meta);')
action_runner.EvaluateJavaScript(viewport_js)
« 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