use of com.hubspot.rosetta.beans.NestedBean in project Rosetta by HubSpot.
the class RosettaBinderTest method itBindsNestedBeanCorrectly.
@Test
public void itBindsNestedBeanCorrectly() {
InnerBean inner = new InnerBean();
inner.setStringProperty("value");
NestedBean bean = new NestedBean();
bean.setInner(inner);
assertThat(bind(bean)).isEqualTo(map("inner.stringProperty", "value"));
assertThat(bindWithPrefix("prefix", bean)).isEqualTo(map("prefix.inner.stringProperty", "value"));
}
Aggregations