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

Side by Side Diff: chrome/test/functional/perf.py

Issue 8574067: Adding pyauto-based perf test for WebGL SpaceRocks demo. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/python
2 # Copyright (c) 2011 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2011 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 """Basic pyauto performance tests. 6 """Basic pyauto performance tests.
7 7
8 For tests that need to be run for multiple iterations (e.g., so that average 8 For tests that need to be run for multiple iterations (e.g., so that average
9 and standard deviation values can be reported), the default number of iterations 9 and standard deviation values can be reported), the default number of iterations
10 run for each of these tests is specified by |_DEFAULT_NUM_ITERATIONS|. 10 run for each of these tests is specified by |_DEFAULT_NUM_ITERATIONS|.
(...skipping 641 matching lines...) Expand 10 before | Expand all | Expand 10 after
652 'aquarium.html'), 652 'aquarium.html'),
653 'WebGLAquarium') 653 'WebGLAquarium')
654 654
655 def testWebGLField(self): 655 def testWebGLField(self):
656 """Measures performance using the WebGL Field demo.""" 656 """Measures performance using the WebGL Field demo."""
657 self._RunWebGLTest( 657 self._RunWebGLTest(
658 self.GetFileURLForDataPath('pyauto_private', 'webgl', 'field', 658 self.GetFileURLForDataPath('pyauto_private', 'webgl', 'field',
659 'field.html'), 659 'field.html'),
660 'WebGLField') 660 'WebGLField')
661 661
662 def testWebGLSpaceRocks(self):
663 """Measures performance using the WebGL SpaceRocks demo."""
664 self._RunWebGLTest(
665 self.GetFileURLForDataPath('pyauto_private', 'webgl', 'spacerocks',
666 'spacerocks.html'),
667 'WebGLSpaceRocks')
668
662 669
663 class FileUploadDownloadTest(BasePerfTest): 670 class FileUploadDownloadTest(BasePerfTest):
664 """Tests that involve measuring performance of upload and download.""" 671 """Tests that involve measuring performance of upload and download."""
665 672
666 def setUp(self): 673 def setUp(self):
667 """Performs necessary setup work before running each test in this class.""" 674 """Performs necessary setup work before running each test in this class."""
668 self._temp_dir = tempfile.mkdtemp() 675 self._temp_dir = tempfile.mkdtemp()
669 self._test_server = PerfTestServer(self._temp_dir) 676 self._test_server = PerfTestServer(self._temp_dir)
670 self._test_server_port = self._test_server.GetPort() 677 self._test_server_port = self._test_server.GetPort()
671 self._test_server.Run() 678 self._test_server.Run()
(...skipping 645 matching lines...) Expand 10 before | Expand all | Expand 10 after
1317 """Identifies the port number to which the server is currently bound. 1324 """Identifies the port number to which the server is currently bound.
1318 1325
1319 Returns: 1326 Returns:
1320 The numeric port number to which the server is currently bound. 1327 The numeric port number to which the server is currently bound.
1321 """ 1328 """
1322 return self._server.server_address[1] 1329 return self._server.server_address[1]
1323 1330
1324 1331
1325 if __name__ == '__main__': 1332 if __name__ == '__main__':
1326 pyauto_functional.Main() 1333 pyauto_functional.Main()
OLDNEW
« 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