Thread
#compose
    f

    Filip Zych

    2 years ago
    Not sure if there was already such a question, but will robolectric work with compose?
    l

    Leland Richardson [G]

    2 years ago
    a

    allan.conda

    2 years ago
    Does Robolectric still work? Latest seems to fail currently due to the composeTestRule.
    java.lang.NullPointerException: runOnUiThread {
            Choreographer.getInstance()
        } must not be null
    
    	at androidx.ui.test.android.AndroidTestAnimationClock.<init>(AndroidTestAnimationClock.kt:45)
    	at androidx.ui.test.AnimationClockTestRule.<init>(TestAnimationClock.kt:90)
    	at androidx.ui.test.android.AndroidComposeTestRule.<init>(AndroidComposeTestRule.kt:97)
    	at androidx.ui.test.ComposeTestRuleKt.createComposeRule(ComposeTestRule.kt:104)
    	at androidx.ui.test.ComposeTestRuleKt.createComposeRule$default(ComposeTestRule.kt:90)
    Trying to find a solution… I need to replace it with ShadowChoreographer somehow Test works fine in androidTest however.