---
title: "ViewRootForTest"
description: "The marker interface to be implemented by the [View] backing the composition. To be used in
tests."
type: "interface"
---

<div class='type'>Interface</div>


<a id='references'></a>

<div class='sourceset sourceset-android'>Android</div>



```kotlin
@VisibleForTesting
interface ViewRootForTest : RootForTest
```


The marker interface to be implemented by the `View` backing the composition. To be used in
tests.


## Properties

<div class='sourceset sourceset-android'>Android</div>


```kotlin
val view: View
```


The view backing this Owner.



<div class='sourceset sourceset-android'>Android</div>


```kotlin
val isLifecycleInResumedState: Boolean
```


Returns true when the associated LifecycleOwner is in the resumed state



<div class='sourceset sourceset-android'>Android</div>


```kotlin
val hasPendingMeasureOrLayout: Boolean
```


Whether the Owner has pending layout work.



## Functions

```kotlin
fun invalidateDescendants()
```


Called to invalidate the Android `View` sub-hierarchy handled by this `View`.



