|
@@ -1148,6 +1148,16 @@ public class StackControllerTest extends BaseTest {
|
1148
|
1148
|
assertThat(uut.getTopInset(child1)).isEqualTo(0);
|
1149
|
1149
|
}
|
1150
|
1150
|
|
|
1151
|
+ @Test
|
|
1152
|
+ public void getTopInset_defaultOptionsAreTakenIntoAccount() {
|
|
1153
|
+ assertThat(uut.getTopInset(child1)).isEqualTo(topBarController.getHeight());
|
|
1154
|
+ Options defaultOptions = new Options();
|
|
1155
|
+ defaultOptions.topBar.drawBehind = new Bool(true);
|
|
1156
|
+ uut.setDefaultOptions(defaultOptions);
|
|
1157
|
+
|
|
1158
|
+ assertThat(uut.getTopInset(child1)).isZero();
|
|
1159
|
+ }
|
|
1160
|
+
|
1151
|
1161
|
private void assertContainsOnlyId(String... ids) {
|
1152
|
1162
|
assertThat(uut.size()).isEqualTo(ids.length);
|
1153
|
1163
|
assertThat(uut.getChildControllers()).extracting((Extractor<ViewController, String>) ViewController::getId).containsOnly(ids);
|