Release Preview 20 shared desktop, Android and Sargo updates
Restore Gaia settings and media workflows, extend native network adapters, and align the APK payload. Generate French/English changelogs and website entries from the simplified JSON source. Validation: shared JS and Tundra unit tests; desktop workflows and persistence; signed APK payload parity; Sargo RAM and installed startup with boot readback. Android runtime qualification is recorded separately.
This commit is contained in:
parent
be2cdce823
commit
1311bed5e9
170 changed files with 19698 additions and 2495 deletions
22
tundra/tests/test_bluetooth_control.py
Normal file
22
tundra/tests/test_bluetooth_control.py
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
import importlib.util
|
||||
from pathlib import Path
|
||||
import unittest
|
||||
|
||||
spec=importlib.util.spec_from_file_location('bluetooth',Path(__file__).resolve().parents[1]/'runtime/bluetooth-control.py')
|
||||
bt=importlib.util.module_from_spec(spec);spec.loader.exec_module(bt)
|
||||
|
||||
class Bluetooth(unittest.TestCase):
|
||||
def test_reject_arbitrary_path_command_and_non_boolean_power(self):
|
||||
for value in [dict(operation='exec',command='id'),dict(operation='pair',address='/org/bluez/hci0'),
|
||||
dict(operation='power',enabled='false'),dict(operation='rename',name='\nName')]:
|
||||
with self.assertRaises(ValueError):bt.validate(dict(version=1,**value))
|
||||
def test_valid_pair_and_name(self):
|
||||
self.assertEqual(bt.validate(dict(version=1,operation='pair',address='AA:BB:CC:DD:EE:FF')),'pair')
|
||||
self.assertEqual(bt.validate(dict(version=1,operation='rename',name='Vulpes OS')),'rename')
|
||||
def test_cod_for_gaia_and_no_manufactured_connection(self):
|
||||
value=bt.device_record(dict(Address='AA:BB:CC:DD:EE:FF',Class=0x240404,Paired=True))
|
||||
self.assertEqual(value['cod']['majorDeviceClass'],4)
|
||||
self.assertEqual(value['cod']['minorDeviceClass'],1)
|
||||
self.assertTrue(value['paired']);self.assertFalse(value['connected'])
|
||||
|
||||
if __name__=='__main__':unittest.main()
|
||||
Loading…
Reference in a new issue