| 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 import logging | 5 import logging |
| 6 import os | 6 import os |
| 7 import unittest | 7 import unittest |
| 8 | 8 |
| 9 from telemetry.core import discover | |
| 10 from telemetry.internal.browser import browser_credentials | 9 from telemetry.internal.browser import browser_credentials |
| 11 from telemetry.internal import story_runner | 10 from telemetry.internal import story_runner |
| 12 from telemetry import page | 11 from telemetry import page |
| 13 from telemetry import story as story_module | 12 from telemetry import story as story_module |
| 14 from telemetry.wpr import archive_info | 13 from telemetry.wpr import archive_info |
| 15 | 14 |
| 15 from py_utils import discover |
| 16 | 16 |
| 17 class StorySetSmokeTest(unittest.TestCase): | 17 class StorySetSmokeTest(unittest.TestCase): |
| 18 | 18 |
| 19 def setUp(self): | 19 def setUp(self): |
| 20 # Make sure the added failure message is appended to the default failure | 20 # Make sure the added failure message is appended to the default failure |
| 21 # message. | 21 # message. |
| 22 self.longMessage = True | 22 self.longMessage = True |
| 23 | 23 |
| 24 def GetAllStorySetClasses(self, story_sets_dir, top_level_dir): | 24 def GetAllStorySetClasses(self, story_sets_dir, top_level_dir): |
| 25 # We can't test page sets that aren't directly constructible since we | 25 # We can't test page sets that aren't directly constructible since we |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 method to run smoke test. | 146 method to run smoke test. |
| 147 """ | 147 """ |
| 148 story_sets = self.GetAllStorySetClasses(story_sets_dir, top_level_dir) | 148 story_sets = self.GetAllStorySetClasses(story_sets_dir, top_level_dir) |
| 149 for story_set_class in story_sets: | 149 for story_set_class in story_sets: |
| 150 story_set = story_set_class() | 150 story_set = story_set_class() |
| 151 self.CheckArchive(story_set) | 151 self.CheckArchive(story_set) |
| 152 self.CheckCredentials(story_set) | 152 self.CheckCredentials(story_set) |
| 153 self.CheckAttributes(story_set) | 153 self.CheckAttributes(story_set) |
| 154 self.CheckSharedStates(story_set) | 154 self.CheckSharedStates(story_set) |
| 155 self.CheckPassingStoryRunnerValidation(story_set) | 155 self.CheckPassingStoryRunnerValidation(story_set) |
| OLD | NEW |