Release Vulpes OS 2.7 Preview 25 for Desktop, Android and Pixel 3a
This commit is contained in:
parent
6a44daeaaa
commit
3a1fba4efe
1 changed files with 1301 additions and 196 deletions
|
|
@ -15,6 +15,15 @@ spec.loader.exec_module(radio)
|
|||
|
||||
|
||||
class RadioControlTests(unittest.TestCase):
|
||||
def test_imei_uses_modem_without_network_registration(self):
|
||||
serial = '0' * 15
|
||||
with patch.object(radio, 'bus', return_value=[{'Serial': {'data': serial}}]) as query:
|
||||
self.assertEqual(radio.request({'version': 1, 'operation': 'imei'}), serial)
|
||||
query.assert_called_once_with('org.ofono', radio.MODEM, 'org.ofono.Modem', 'GetProperties')
|
||||
with patch.object(radio, 'bus', return_value=[{'Serial': {'data': 'unknown'}}]):
|
||||
with self.assertRaisesRegex(RuntimeError, 'RADIO_NOT_READY'):
|
||||
radio.request({'version': 1, 'operation': 'imei'})
|
||||
|
||||
def test_message_state_accepts_modem_hex_case_but_not_other_objects(self):
|
||||
inbox = SimpleNamespace(outgoing_state=lambda path: 'sent')
|
||||
spec = SimpleNamespace(loader=SimpleNamespace(exec_module=lambda module: None))
|
||||
|
|
|
|||
Loading…
Reference in a new issue