| OLD | NEW |
| 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 """Run all system health stories used by system health benchmarks. | 5 """Run all system health stories used by system health benchmarks. |
| 6 | 6 |
| 7 Only memory benchmarks are used when running these stories to make the total | 7 Only memory benchmarks are used when running these stories to make the total |
| 8 cycle time manageable. Other system health benchmarks should be using the same | 8 cycle time manageable. Other system health benchmarks should be using the same |
| 9 stories as memory ones, only with fewer actions (no memory dumping). | 9 stories as memory ones, only with fewer actions (no memory dumping). |
| 10 """ | 10 """ |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 system_health, perf_benchmark.PerfBenchmark, | 28 system_health, perf_benchmark.PerfBenchmark, |
| 29 index_by_class_name=True).values() | 29 index_by_class_name=True).values() |
| 30 return list(b for b in sh_benchmark_classes if | 30 return list(b for b in sh_benchmark_classes if |
| 31 b.Name().startswith('system_health.memory')) | 31 b.Name().startswith('system_health.memory')) |
| 32 | 32 |
| 33 | 33 |
| 34 _DISABLED_TESTS = frozenset({ | 34 _DISABLED_TESTS = frozenset({ |
| 35 # crbug.com/629123 | 35 # crbug.com/629123 |
| 36 'benchmarks.system_health_smoke_test.SystemHealthBenchmarkSmokeTest.system_hea
lth.memory_mobile.browse:news:hackernews', # pylint: disable=line-too-long | 36 'benchmarks.system_health_smoke_test.SystemHealthBenchmarkSmokeTest.system_hea
lth.memory_mobile.browse:news:hackernews', # pylint: disable=line-too-long |
| 37 'benchmarks.system_health_smoke_test.SystemHealthBenchmarkSmokeTest.system_hea
lth.memory_mobile.browse:news:nytimes', # pylint: disable=line-too-long | 37 'benchmarks.system_health_smoke_test.SystemHealthBenchmarkSmokeTest.system_hea
lth.memory_mobile.browse:news:nytimes', # pylint: disable=line-too-long |
| 38 # crbug.com/637230 |
| 39 'benchmarks.system_health_smoke_test.SystemHealthBenchmarkSmokeTest.system_hea
lth.memory_desktop.browse:news:cnn', # pylint: disable=line-too-long |
| 38 }) | 40 }) |
| 39 | 41 |
| 40 | 42 |
| 41 def _GenerateSmokeTestCase(benchmark_class, story_to_smoke_test): | 43 def _GenerateSmokeTestCase(benchmark_class, story_to_smoke_test): |
| 42 | 44 |
| 43 # NOTE TO SHERIFFS: DO NOT DISABLE THIS TEST. | 45 # NOTE TO SHERIFFS: DO NOT DISABLE THIS TEST. |
| 44 # | 46 # |
| 45 # This smoke test dynamically tests all system health user stories. So | 47 # This smoke test dynamically tests all system health user stories. So |
| 46 # disabling it for one failing or flaky benchmark would disable a much | 48 # disabling it for one failing or flaky benchmark would disable a much |
| 47 # wider swath of coverage than is usally intended. Instead, if a test is | 49 # wider swath of coverage than is usally intended. Instead, if a test is |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 # parsed during test time which happens after load_tests are called. | 125 # parsed during test time which happens after load_tests are called. |
| 124 # Since none of our system health benchmarks creates stories based on | 126 # Since none of our system health benchmarks creates stories based on |
| 125 # command line options, it should be ok to pass options=None to | 127 # command line options, it should be ok to pass options=None to |
| 126 # CreateStorySet. | 128 # CreateStorySet. |
| 127 for story_to_smoke_test in ( | 129 for story_to_smoke_test in ( |
| 128 benchmark_class().CreateStorySet(options=None).stories): | 130 benchmark_class().CreateStorySet(options=None).stories): |
| 129 suite.addTest( | 131 suite.addTest( |
| 130 _GenerateSmokeTestCase(benchmark_class, story_to_smoke_test)) | 132 _GenerateSmokeTestCase(benchmark_class, story_to_smoke_test)) |
| 131 | 133 |
| 132 return suite | 134 return suite |
| OLD | NEW |