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

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

Issue 2663813003: Roll out framework change & update gpu tests to conform to the API changes (Closed)
Patch Set: Roll DEPS to 42d9cffaa797712c58d7b5fb59820f0aa3e82138 Created 3 years, 10 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 2017 The Chromium Authors. All rights reserved. 1 # Copyright 2017 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 json 5 import json
6 import os 6 import os
7 import sys 7 import sys
8 8
9 from gpu_tests import gpu_integration_test 9 from gpu_tests import gpu_integration_test
10 from gpu_tests import cloud_storage_integration_test_base 10 from gpu_tests import cloud_storage_integration_test_base
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 53
54 @classmethod 54 @classmethod
55 def Name(cls): 55 def Name(cls):
56 return 'maps' 56 return 'maps'
57 57
58 @classmethod 58 @classmethod
59 def _CreateExpectations(cls): 59 def _CreateExpectations(cls):
60 return maps_expectations.MapsExpectations() 60 return maps_expectations.MapsExpectations()
61 61
62 @classmethod 62 @classmethod
63 def setUpClass(cls): 63 def SetUpProcess(cls):
64 super(cls, MapsIntegrationTest).setUpClass() 64 super(cls, MapsIntegrationTest).SetUpProcess()
65 cls.SetBrowserOptions(cls._finder_options) 65 cls.SetBrowserOptions(cls._finder_options)
66 cls.StartWPRServer(os.path.join(data_path, 'maps_004.wpr.updated'), 66 cls.StartWPRServer(os.path.join(data_path, 'maps_004.wpr.updated'),
67 cloud_storage.PUBLIC_BUCKET) 67 cloud_storage.PUBLIC_BUCKET)
68 cls.StartBrowser() 68 cls.StartBrowser()
69 69
70 @classmethod 70 @classmethod
71 def tearDownClass(cls): 71 def TearDownProcess(cls):
72 super(cls, MapsIntegrationTest).tearDownClass() 72 super(cls, MapsIntegrationTest).TearDownProcess()
73 cls.StopWPRServer() 73 cls.StopWPRServer()
74 74
75 @classmethod 75 @classmethod
76 def GenerateGpuTests(cls, options): 76 def GenerateGpuTests(cls, options):
77 cls.SetParsedCommandLineOptions(options) 77 cls.SetParsedCommandLineOptions(options)
78 yield('Maps_maps_004', 78 yield('Maps_maps_004',
79 'http://map-test/performance.html', 79 'http://map-test/performance.html',
80 ('maps_004_expectations.json')) 80 ('maps_004_expectations.json'))
81 81
82 def _ReadPixelExpectations(self, expectations_file): 82 def _ReadPixelExpectations(self, expectations_file):
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 # screenshot are observed. Hack around this by specifying a scale 131 # screenshot are observed. Hack around this by specifying a scale
132 # factor for these bots in the test expectations. This relies on 132 # factor for these bots in the test expectations. This relies on
133 # the test-machine-name argument being specified on the command 133 # the test-machine-name argument being specified on the command
134 # line. 134 # line.
135 expected = self._ReadPixelExpectations(pixel_expectations_file) 135 expected = self._ReadPixelExpectations(pixel_expectations_file)
136 self._ValidateScreenshotSamples(tab, url, screenshot, expected, dpr) 136 self._ValidateScreenshotSamples(tab, url, screenshot, expected, dpr)
137 137
138 def load_tests(loader, tests, pattern): 138 def load_tests(loader, tests, pattern):
139 del loader, tests, pattern # Unused. 139 del loader, tests, pattern # Unused.
140 return gpu_integration_test.LoadAllTestsInModule(sys.modules[__name__]) 140 return gpu_integration_test.LoadAllTestsInModule(sys.modules[__name__])
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698