|
@@ -153,4 +153,14 @@
|
153
|
153
|
XCTAssertTrue(uut.selectedIndex == 1);
|
154
|
154
|
}
|
155
|
155
|
|
|
156
|
+- (void)testSetSelectedIndex_ShouldSetSelectedIndexWithCurrentTabIndex {
|
|
157
|
+ RNNNavigationOptions* options = [[RNNNavigationOptions alloc] initEmptyOptions];
|
|
158
|
+ options.bottomTabs.currentTabIndex = [[IntNumber alloc] initWithValue:@(1)];
|
|
159
|
+
|
|
160
|
+ RNNRootViewController* vc = [[RNNRootViewController alloc] initWithLayoutInfo:nil rootViewCreator:nil eventEmitter:nil presenter:nil options:nil defaultOptions:nil];
|
|
161
|
+ RNNTabBarController* uut = [[RNNTabBarController alloc] initWithLayoutInfo:nil creator:nil options:options defaultOptions:nil presenter:[RNNTabBarPresenter new] eventEmitter:nil childViewControllers:@[[UIViewController new], vc]];
|
|
162
|
+
|
|
163
|
+ XCTAssertTrue(uut.selectedIndex == 1);
|
|
164
|
+}
|
|
165
|
+
|
156
|
166
|
@end
|