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

Side by Side Diff: content/test/gpu/gpu_tests/context_lost_integration_test.py

Issue 2503453003: Remove all calls to domAutomationController.setAutomationId.
Patch Set: Fix nacl_browsertest_util.cc Created 3 years, 5 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 unified diff | Download patch
OLDNEW
1 # Copyright 2016 The Chromium Authors. All rights reserved. 1 # Copyright 2016 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 import os 5 import os
6 import sys 6 import sys
7 import time 7 import time
8 8
9 from gpu_tests import gpu_integration_test 9 from gpu_tests import gpu_integration_test
10 from gpu_tests import context_lost_expectations 10 from gpu_tests import context_lost_expectations
11 from gpu_tests import path_util 11 from gpu_tests import path_util
12 12
13 from telemetry.core import exceptions 13 from telemetry.core import exceptions
14 14
15 data_path = os.path.join( 15 data_path = os.path.join(
16 path_util.GetChromiumSrcDir(), 'content', 'test', 'data', 'gpu') 16 path_util.GetChromiumSrcDir(), 'content', 'test', 'data', 'gpu')
17 17
18 wait_timeout = 60 # seconds 18 wait_timeout = 60 # seconds
19 19
20 harness_script = r""" 20 harness_script = r"""
21 var domAutomationController = {}; 21 var domAutomationController = {};
22 22
23 domAutomationController._loaded = false; 23 domAutomationController._loaded = false;
24 domAutomationController._succeeded = false; 24 domAutomationController._succeeded = false;
25 domAutomationController._finished = false; 25 domAutomationController._finished = false;
26 26
27 domAutomationController.setAutomationId = function(id) {}
28
29 domAutomationController.send = function(msg) { 27 domAutomationController.send = function(msg) {
30 msg = msg.toLowerCase() 28 msg = msg.toLowerCase()
31 if (msg == "loaded") { 29 if (msg == "loaded") {
32 domAutomationController._loaded = true; 30 domAutomationController._loaded = true;
33 } else if (msg == "success") { 31 } else if (msg == "success") {
34 /* Don't squelch earlier failures! */ 32 /* Don't squelch earlier failures! */
35 if (!domAutomationController._finished) { 33 if (!domAutomationController._finished) {
36 domAutomationController._succeeded = true; 34 domAutomationController._succeeded = true;
37 } 35 }
38 domAutomationController._finished = true; 36 domAutomationController._finished = true;
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
246 # doesn't crash. 244 # doesn't crash.
247 tab = self.tab 245 tab = self.tab
248 dummy_tab = tab.browser.tabs.New() 246 dummy_tab = tab.browser.tabs.New()
249 tab.EvaluateJavaScript('loseContextUsingExtension()') 247 tab.EvaluateJavaScript('loseContextUsingExtension()')
250 tab.Activate() 248 tab.Activate()
251 self._WaitForTabAndCheckCompletion() 249 self._WaitForTabAndCheckCompletion()
252 250
253 def load_tests(loader, tests, pattern): 251 def load_tests(loader, tests, pattern):
254 del loader, tests, pattern # Unused. 252 del loader, tests, pattern # Unused.
255 return gpu_integration_test.LoadAllTestsInModule(sys.modules[__name__]) 253 return gpu_integration_test.LoadAllTestsInModule(sys.modules[__name__])
OLDNEW
« no previous file with comments | « content/test/data/simple_database.html ('k') | content/test/gpu/gpu_tests/depth_capture_integration_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698