Last active
September 2, 2019 15:59
-
-
Save JoseAlcerreca/306de84d2522dcc9fefed4345b88a71f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Copyright 2019 Google LLC. | |
SPDX-License-Identifier: Apache-2.0 */ | |
@Test | |
fun isLiveDataEmitting_getOrAwaitValue() { | |
viewModel.setNewValue("foo") | |
// Pass: | |
assertEquals(viewModel.liveData1.getOrAwaitValue(), "foo") | |
assertEquals(viewModel.liveData2.getOrAwaitValue(), "FOO") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment