Package com.tomtom.ivi.platform.frontend.api.testing.fragment

This package contains FragmentScenario to launch a fragment with applied stock themes. It can be used in integration tests to get themed views.

Functions

Link copied to clipboard
inline fun <F : Fragment> launchStockFragment(    context: Context,     fragmentArgs: Bundle? = null,     crossinline instantiate: () -> F): FragmentScenario<F>

Applies all the Stock themes and then launches a Fragment with given arguments hosted by an empty FragmentActivity using instantiate to create the Fragment and waits for it to reach a resumed state.

Link copied to clipboard
inline fun <F : Fragment> launchStockFragmentInContainer(    context: Context,     fragmentArgs: Bundle? = null,     crossinline instantiate: () -> F): FragmentScenario<F>

Applies all the Stock themes and then launches a Fragment in the Activity's root view container android.R.id.content, with given arguments hosted by an empty FragmentActivity using instantiate to create the Fragment and waits for it to reach a resumed state.