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

Commit 28324d9f authored by Sungsoo Lim's avatar Sungsoo Lim
Browse files

Fix BrowsablePlayerConnectorTest

BrowsedPlayerWrapper.getFolderItems() could be called some time
later after the first connect which causes another call of connect().

Bug: 298674899
Test: atest BluetoothInstrumentationTests
Change-Id: I3a1119784f386767e21abb11db0f159de65fa482
parent e46fa9c1
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -96,7 +96,7 @@ public final class BrowsablePlayerConnectorTest {
                        mTestLooper.getLooper(),
                        mPlayerList,
                        (List<BrowsedPlayerWrapper> players) -> latch.countDown());
        verify(mMediaBrowser, timeout(TIMEOUT_MS)).connect();
        verify(mMediaBrowser, timeout(TIMEOUT_MS).atLeast(1)).connect();
        assertThat(latch.await(TIMEOUT_MS, TimeUnit.MILLISECONDS)).isTrue();
        connector.cleanup();
        mTestLooper.stopAutoDispatch();
@@ -111,7 +111,7 @@ public final class BrowsablePlayerConnectorTest {
                        mTestLooper.getLooper(),
                        mPlayerList,
                        (List<BrowsedPlayerWrapper> players) -> {});
        verify(mMediaBrowser, timeout(TIMEOUT_MS)).connect();
        verify(mMediaBrowser, timeout(TIMEOUT_MS).atLeast(1)).connect();
        connector.cleanup();
        mTestLooper.dispatchAll();
    }