Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8f4eb936 authored by William Escande's avatar William Escande
Browse files

Add delay in the restart test

Test: atest BluetoothInstrumentationTests
Bug: 267528843
Change-Id: I188817c3f5eebe1bb42ea86766471117d899297e
parent a2c6b485
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -330,6 +330,12 @@ public class AdapterServiceRestartTest {
    @Test
    public void testObfuscateBluetoothAddress_PersistentBetweenAdapterServiceInitialization() throws
            PackageManager.NameNotFoundException {
        // Sleep needed to ensure the metrics are valid in both native and java (b/267528843)
        try {
            Thread.sleep(1_000);
        } catch (InterruptedException e) {
            Log.e("AdapterServiceTest", "Sleep interrupted: " + e);
        }
        byte[] metricsSalt = AdapterServiceTest.getMetricsSalt(mAdapterConfig);
        Assert.assertNotNull(metricsSalt);
        Assert.assertFalse(mAdapterService.getState() == BluetoothAdapter.STATE_ON);