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 3# found in the LICENSE file. 4import unittest 5 6from telemetry.core import browser_options 7from telemetry.core.backends.chrome import ios_browser_finder 8from telemetry.unittest import test 9 10 11class IosBrowserFinderUnitTest(unittest.TestCase): 12 # TODO(baxley): Currently the tests require a device with Chrome running. 13 # This should be stubbed out so it runs on any system, with no device 14 # dependencies. 15 @test.Enabled('ios') 16 def testFindIosChrome(self): 17 finder_options = browser_options.BrowserFinderOptions() 18 browsers = ios_browser_finder.FindAllAvailableBrowsers(finder_options) 19 self.assertTrue(browsers) 20 for browser in browsers: 21 self.assertEqual('ios-chrome', browser.browser_type) 22 23if __name__ == '__main__': 24 unittest.main() 25