Support mock STHAL
Have SoundTriggerMiddlewareService try to connect to a "mock"
instance of the HAL, instead of "default", whenever the system
property debug.soundtrigger_middleware.use_mock_hal is set.
This allows, e.g., a test to register a mock HAL and have the real
service connect to it. Simulation of a HAL reboot can be achieved via
the debug() API.
This change also updates the properties of the HAL every time it
reattaches, in order to reflect the mock HAL properties. In a
production this is meaningless.
Test: Manual verification of no regression and of support of the mock
HAL when present.
Change-Id: I3a3105ae1342f460b942c932bd0c56a4b6e7812d
Loading
Please register or sign in to comment