use of com.reactnativenavigation.options.params.Bool in project react-native-navigation by wix.
the class ComponentViewControllerTest method getTopInset_drawBehind_defaultOptions.
@Test
public void getTopInset_drawBehind_defaultOptions() {
Options defaultOptions = new Options();
defaultOptions.statusBar.drawBehind = new Bool(true);
uut.setDefaultOptions(defaultOptions);
uut.options.topBar.drawBehind = new Bool(true);
Java6Assertions.assertThat(uut.getTopInset()).isEqualTo(0);
}
use of com.reactnativenavigation.options.params.Bool in project react-native-navigation by wix.
the class ComponentViewControllerTest method getTopInset_drawBehind.
@Test
public void getTopInset_drawBehind() {
uut.options.statusBar.drawBehind = new Bool(true);
uut.options.topBar.drawBehind = new Bool(true);
Java6Assertions.assertThat(uut.getTopInset()).isEqualTo(0);
}
use of com.reactnativenavigation.options.params.Bool in project react-native-navigation by wix.
the class SideMenuControllerTest method closeLeftMenu.
private void closeLeftMenu() {
Options options = new Options();
options.sideMenuRootOptions.left.visible = new Bool(false);
options.sideMenuRootOptions.left.animate = new Bool(false);
uut.mergeOptions(options);
uut.onDrawerSlide(left.getView(), 0);
}
use of com.reactnativenavigation.options.params.Bool in project react-native-navigation by wix.
the class SideMenuControllerTest method mergeOptions_openRightSideMenu.
@Test
public void mergeOptions_openRightSideMenu() {
uut.setRightController(new SimpleComponentViewController(activity, childRegistry, "right", new Options()));
Options options = new Options();
options.sideMenuRootOptions.right.visible = new Bool(true);
assertThat(uut.getView().isDrawerOpen(Gravity.RIGHT)).isFalse();
uut.mergeOptions(options);
assertThat(uut.getView().isDrawerOpen(Gravity.RIGHT)).isTrue();
}
use of com.reactnativenavigation.options.params.Bool in project react-native-navigation by wix.
the class SideMenuControllerTest method mergeOptions_openLeftSideMenu.
@Test
public void mergeOptions_openLeftSideMenu() {
uut.setLeftController(new SimpleComponentViewController(activity, childRegistry, "left", new Options()));
Options options = new Options();
options.sideMenuRootOptions.left.visible = new Bool(true);
assertThat(uut.getView().isDrawerOpen(Gravity.LEFT)).isFalse();
uut.mergeOptions(options);
assertThat(uut.getView().isDrawerOpen(Gravity.LEFT)).isTrue();
}
Aggregations