Function

onRootWithViewInteraction

Scopes the Compose interaction to the View hierarchy matched by the provided Espresso ViewInteraction.

onRootWithViewInteraction

Source set: Android
@ExperimentalTestApi
fun ComposeUiTest.onRootWithViewInteraction(
    interaction: ViewInteraction
): SemanticsNodeInteractionsProvider

Scopes the Compose interaction to the View hierarchy matched by the provided Espresso ViewInteraction.

It resolves the View from the Espresso interaction, locates all Compose roots within that view hierarchy, and creates a new, scoped SemanticsNodeInteractionsProvider.

Last updated: