public class SubComponent extends Object
ComponentLifecycle
s.
Useful for verifying the existence of sub-components that are part of a layout.Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
Component<?> |
getComponent() |
Class<? extends ComponentLifecycle> |
getComponentType() |
int |
hashCode() |
static <any> |
legacySubComponent(SubComponent subComponent)
Use an old-style
SubComponent in an assertj Condition. |
static SubComponent |
of(Class<? extends ComponentLifecycle> componentType) |
static SubComponent |
of(Component component) |
String |
toString() |
public static SubComponent of(Class<? extends ComponentLifecycle> componentType)
public static SubComponent of(Component component)
public Component<?> getComponent()
public Class<? extends ComponentLifecycle> getComponentType()
public static <any> legacySubComponent(SubComponent subComponent)
SubComponent
in an assertj Condition.
For instance:
assertThat(c, mComponent)
.has(
subComponentWith(
c,
legacySubComponent(
SubComponent.of(
FooterComponent.create(c).text("Rockstar Developer").build()))));
subComponent
- The constructed of(Component)
.org.assertj.core.api.Assertions#assertThat