Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/imported/wpt/resources/testharnessreport.js |
| diff --git a/third_party/WebKit/LayoutTests/imported/wpt/resources/testharnessreport.js b/third_party/WebKit/LayoutTests/imported/wpt/resources/testharnessreport.js |
| index 64c08a922e7b4a1fa004960fd22c6aeeb80ac7b3..0dba6f206509b4ec011452b8b5f3a6cfddc03b87 100644 |
| --- a/third_party/WebKit/LayoutTests/imported/wpt/resources/testharnessreport.js |
| +++ b/third_party/WebKit/LayoutTests/imported/wpt/resources/testharnessreport.js |
| @@ -66,9 +66,19 @@ |
| return !!document.querySelector('script[src*="/resources/testharness"]'); |
| } |
|
Rick Byers
2016/07/05 15:01:30
There's not supposed to be a 2nd copy of the 'reso
Navid Zolghadr
2016/07/05 15:42:20
Yes. I did it manually. There is a presubmit check
|
| + |
| function injectSyntheticInput() { |
| var path = window.location.pathname; |
| if (path.match(/imported\/wpt\/.*\.html$/)) { |
| + // Set a global variable for the address of automated input script if they need to use it. |
| + var automated_input_scripts_folder = path.replace(/imported\/wpt\/(.*)\.html$/, 'imported/wpt_automation'); |
| + |
| + importAutomationScript = function(relativePath) { |
| + var common_script = document.createElement('script'); |
| + common_script.setAttribute('src', automated_input_scripts_folder + relativePath); |
| + document.head.appendChild(common_script); |
| + } |
| + |
| path = path.replace(/imported\/wpt\/(.*)\.html$/, "imported/wpt_automation/$1-input.js"); |
| var input_script = document.createElement('script'); |
| input_script.setAttribute('src', path); |