Don't use flag value to decide whether to wait for broadcast.
If the flag is unset, the flag default value will be used. This causes a mismatch because the default flag value we use in the test may differ from the default flag value in production; and thus may not trigger an ENABLED_CHANGED broadcast. We could either make the default value in the test match the default value in system server, or we could use the API to get the source of truth. I went with the latter approach as it doesn't seem to require the maintenance burden of keeping the two in sync. Also happy to go with the former instead. We should follow up on b/269129117 to create a shared library for these values to avoid further similar issues. Bug: 269250378 Test: atest CtsSafetyCenterTestCases Change-Id: I187cd33c8da66b4a1289333cb0a6b352ab4a3393
Loading
Please register or sign in to comment