Increase net_unittest verbosity in isolate mode
[chromium-blink-merge.git] / chrome / test / functional / chromeos_cellular_sanity.py
blob2f06d48933f07216a5ec89dbc6cd61237002f39b
1 #!/usr/bin/env python
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
4 # found in the LICENSE file.
6 import logging
7 import os
8 import sys
9 import time
11 import pyauto_functional
12 import pyauto # pyauto_functional must come before pyauto
14 class ChromeosCellularSanity(pyauto.PyUITest):
15 """Tests for ChromeOS network related functions."""
17 assert os.popen('modem status').read(), 'Device needs modem to run test.'
19 def testConnectCellularNetwork(self):
20 """Connect to the cellular network if present."""
22 self.ConnectToCellularNetwork()
23 self.assertTrue(self.NetworkScan().get('connected_cellular'),
24 'Failed to connect to cellular network.')
25 self.DisconnectFromCellularNetwork()
26 self.assertFalse(self.NetworkScan().get('connected_cellular'),
27 'Failed to disconnect from cellular network.')
30 if __name__ == '__main__':
31 pyauto_functional.Main()