| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 1 # Copyright 2014 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 """Run the first page of one benchmark for every module. | 5 """Run the first page of one benchmark for every module. |
| 6 | 6 |
| 7 Only benchmarks that have a composable measurement are included. | 7 Only benchmarks that have a composable measurement are included. |
| 8 Ideally this test would be comprehensive, however, running one page | 8 Ideally this test would be comprehensive, however, running one page |
| 9 of every benchmark would run impractically long. | 9 of every benchmark would run impractically long. |
| 10 """ | 10 """ |
| 11 | 11 |
| 12 import os | 12 import os |
| 13 import sys | 13 import sys |
| 14 import unittest | 14 import unittest |
| 15 | 15 |
| 16 from telemetry import benchmark as benchmark_module | 16 from telemetry import benchmark as benchmark_module |
| 17 from telemetry.core import discover | 17 from telemetry.core import discover |
| 18 from telemetry.internal.browser import browser_finder | 18 from telemetry.internal.browser import browser_finder |
| 19 from telemetry.testing import options_for_unittests | 19 from telemetry.testing import options_for_unittests |
| 20 from telemetry.testing import progress_reporter | 20 from telemetry.testing import progress_reporter |
| 21 | 21 |
| 22 | |
| 23 from benchmarks import image_decoding | 22 from benchmarks import image_decoding |
| 24 from benchmarks import indexeddb_perf | 23 from benchmarks import indexeddb_perf |
| 25 from benchmarks import jetstream | 24 from benchmarks import jetstream |
| 25 from benchmarks import kraken |
| 26 from benchmarks import memory | 26 from benchmarks import memory |
| 27 from benchmarks import octane | 27 from benchmarks import octane |
| 28 from benchmarks import rasterize_and_record_micro | 28 from benchmarks import rasterize_and_record_micro |
| 29 from benchmarks import repaint | 29 from benchmarks import repaint |
| 30 from benchmarks import spaceport | 30 from benchmarks import spaceport |
| 31 from benchmarks import speedometer | 31 from benchmarks import speedometer |
| 32 from benchmarks import text_selection | 32 from benchmarks import text_selection |
| 33 | 33 |
| 34 | 34 |
| 35 def SmokeTestGenerator(benchmark): | 35 def SmokeTestGenerator(benchmark): |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 83 _BLACK_LIST_TEST_MODULES = { | 83 _BLACK_LIST_TEST_MODULES = { |
| 84 image_decoding, # Always fails on Mac10.9 Tests builder. | 84 image_decoding, # Always fails on Mac10.9 Tests builder. |
| 85 indexeddb_perf, # Always fails on Win7 & Android Tests builder. | 85 indexeddb_perf, # Always fails on Win7 & Android Tests builder. |
| 86 octane, # Often fails & take long time to timeout on cq bot. | 86 octane, # Often fails & take long time to timeout on cq bot. |
| 87 rasterize_and_record_micro, # Always fails on cq bot. | 87 rasterize_and_record_micro, # Always fails on cq bot. |
| 88 repaint, # Often fails & takes long time to timeout on cq bot. | 88 repaint, # Often fails & takes long time to timeout on cq bot. |
| 89 spaceport, # Takes 451 seconds. | 89 spaceport, # Takes 451 seconds. |
| 90 speedometer, # Takes 101 seconds. | 90 speedometer, # Takes 101 seconds. |
| 91 jetstream, # Take 206 seconds. | 91 jetstream, # Take 206 seconds. |
| 92 text_selection, # Always fails on cq bot. | 92 text_selection, # Always fails on cq bot. |
| 93 memory # Flaky on bots, crbug.com/513767. | 93 memory, # Flaky on bots, crbug.com/513767. |
| 94 kraken, # Flaky on Android, crbug.com/626174. |
| 94 } | 95 } |
| 95 | 96 |
| 96 | 97 |
| 97 def load_tests(loader, standard_tests, pattern): | 98 def load_tests(loader, standard_tests, pattern): |
| 98 del loader, standard_tests, pattern # unused | 99 del loader, standard_tests, pattern # unused |
| 99 suite = progress_reporter.TestSuite() | 100 suite = progress_reporter.TestSuite() |
| 100 | 101 |
| 101 benchmarks_dir = os.path.dirname(__file__) | 102 benchmarks_dir = os.path.dirname(__file__) |
| 102 top_level_dir = os.path.dirname(benchmarks_dir) | 103 top_level_dir = os.path.dirname(benchmarks_dir) |
| 103 | 104 |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 136 merged_attributes = getattr(method, attribute, set()).union( | 137 merged_attributes = getattr(method, attribute, set()).union( |
| 137 getattr(benchmark, attribute, set())) | 138 getattr(benchmark, attribute, set())) |
| 138 if merged_attributes: | 139 if merged_attributes: |
| 139 setattr(method, attribute, merged_attributes) | 140 setattr(method, attribute, merged_attributes) |
| 140 | 141 |
| 141 setattr(BenchmarkSmokeTest, benchmark.Name(), method) | 142 setattr(BenchmarkSmokeTest, benchmark.Name(), method) |
| 142 | 143 |
| 143 suite.addTest(BenchmarkSmokeTest(benchmark.Name())) | 144 suite.addTest(BenchmarkSmokeTest(benchmark.Name())) |
| 144 | 145 |
| 145 return suite | 146 return suite |
| OLD | NEW |