-
Notifications
You must be signed in to change notification settings - Fork 662
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[FC] Removes mavericks from all viewmodels and tests #8155
[FC] Removes mavericks from all viewmodels and tests #8155
Conversation
Diffuse output:
|
…nto carlosmuvi/remove-mavericks-part-3 # Conflicts: # financial-connections/src/test/java/com/stripe/android/financialconnections/features/accountpicker/AccountPickerViewModelTest.kt # financial-connections/src/test/java/com/stripe/android/financialconnections/features/partnerauth/PartnerAuthViewModelTest.kt
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love that we’re getting rid of this ❤️
@@ -994,15 +994,6 @@ | |||
| | | \--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.22 -> 1.9.10 (*) | |||
| | +--- org.jetbrains.kotlinx:kotlinx-coroutines-core:{require 1.6.4; reject _} -> 1.7.3 (*) | |||
| | \--- org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.22 -> 1.9.10 (*) | |||
| +--- com.airbnb.android:mavericks-compose:3.0.9 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔥
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we rename this file or move the extensions?
@@ -42,7 +43,7 @@ import org.mockito.kotlin.whenever | |||
class LinkAccountPickerViewModelTest { | |||
|
|||
@get:Rule | |||
val mavericksTestRule = MavericksTestRule() | |||
val testRule = CoroutineTestRule(UnconfinedTestDispatcher()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit!
val testRule = CoroutineTestRule(UnconfinedTestDispatcher()) | |
val testRule = CoroutineTestRule() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -109,7 +109,7 @@ class LinkStepUpVerificationViewModelTest { | |||
|
|||
val viewModel = buildViewModel() | |||
|
|||
assertThat(viewModel.awaitState().payload).isInstanceOf(Loading::class.java) | |||
assertThat(viewModel.stateFlow.value.payload).isInstanceOf(Loading::class.java) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we test this with Turbine to be more explicit about when we expect a new state and when we don’t?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Added an example asserting no events are emitted after consumer lookup results in no user found)
@get:Rule | ||
val mavericksTestRule = MavericksTestRule(testDispatcher = testDispatcher) | ||
val testRule = CoroutineTestRule(UnconfinedTestDispatcher()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit!
val testRule = CoroutineTestRule(UnconfinedTestDispatcher()) | |
val testRule = CoroutineTestRule() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
1f0f397
into
carlosmuvi/i/remove-mavericks
* [FC] Moves Activities and some Panes out of Mavericks (#8125) * Removes mackericks references on Consent screen. * Updates files. * Uses viewmodel factory builder. * Updates functions. * Updates execute. * Updates compose util. * Adds missing side effects. * Simplifies code. * Renames viewmodel. * Updates async. * Removes mavericks from institution picker. * Reverts rename. * Updates baseline. * Adds setState and persists state. * Renames result error to fail. * Migrates Initial activity out of mavericks. * Removes persist state. * Updates tests. * Regenerates API. * filterNotNull. * Nits. * Updates async. * use suspend block. * Update financial-connections/src/main/java/com/stripe/android/financialconnections/core/FinancialConnectionsViewModel.kt Co-authored-by: Till Hellmund <tillh@stripe.com> * Tries onAsync. * Moves activity to stripe ui core. * PR feedback. * Regenerates deps. --------- Co-authored-by: Till Hellmund <tillh@stripe.com> * [FC] Removes mavericks from repositories and more panes. (#8154) * Migrates more screens out of mavs. * Migrates partner auth. * Removes active auth session field. * Updates tests. * Updates attach payment viewmodel. * PR feedback. * Api dump. * [FC] Removes mavericks from all viewmodels and tests (#8155) * Migrates more screens out of mavs. * Migrates partner auth. * Removes active auth session field. * Updates tests. * Updates attach payment viewmodel. * PR feedback. * Api dump. * Migrates missing viewmodels. * Updates dependencies. * PR feedback. * Merge master. * [FC] Removes mavericks dependency (#8160) * Migrates more screens out of mavs. * Migrates partner auth. * Removes active auth session field. * Updates tests. * Updates attach payment viewmodel. * PR feedback. * Api dump. * Migrates missing viewmodels. * Updates dependencies. * Removes mavericks dependency. * Merge with integration. * Uses collect. * Updates dependencies * Updates Changelog. * Update CHANGELOG.md Co-authored-by: Till Hellmund <tillh@stripe.com> --------- Co-authored-by: Till Hellmund <tillh@stripe.com>
Summary
Motivation
Testing
Screenshots
Changelog