|
@@ -414,8 +414,8 @@
|
414
|
414
|
|
415
|
415
|
-(void)testRightButtonsWithTitle_withoutStyle {
|
416
|
416
|
self.options.topBar.rightButtons = @[@{@"id": @"testId", @"text": @"test"}];
|
417
|
|
- __unused RNNNavigationController* nav = [self createNavigationController];
|
418
|
|
- [self.uut viewWillAppear:false];
|
|
417
|
+ self.uut = [[RNNRootViewController alloc] initWithLayoutInfo:nil rootViewCreator:nil eventEmitter:nil presenter:[RNNViewControllerPresenter new] options:self.options defaultOptions:nil];
|
|
418
|
+ RNNNavigationController* nav = [[RNNNavigationController alloc] initWithLayoutInfo:nil childViewControllers:@[self.uut] options:nil defaultOptions:nil presenter:nil];
|
419
|
419
|
|
420
|
420
|
RNNUIBarButtonItem* button = (RNNUIBarButtonItem*)[nav.topViewController.navigationItem.rightBarButtonItems objectAtIndex:0];
|
421
|
421
|
NSString* expectedButtonId = @"testId";
|
|
@@ -429,8 +429,8 @@
|
429
|
429
|
NSNumber* inputColor = @(0xFFFF0000);
|
430
|
430
|
|
431
|
431
|
self.options.topBar.rightButtons = @[@{@"id": @"testId", @"text": @"test", @"enabled": @false, @"buttonColor": inputColor, @"buttonFontSize": @22, @"buttonFontWeight": @"800"}];
|
432
|
|
- __unused RNNNavigationController* nav = [self createNavigationController];
|
433
|
|
- [self.uut viewWillAppear:false];
|
|
432
|
+ self.uut = [[RNNRootViewController alloc] initWithLayoutInfo:nil rootViewCreator:nil eventEmitter:nil presenter:[RNNViewControllerPresenter new] options:self.options defaultOptions:nil];
|
|
433
|
+ RNNNavigationController* nav = [[RNNNavigationController alloc] initWithLayoutInfo:nil childViewControllers:@[self.uut] options:nil defaultOptions:nil presenter:nil];
|
434
|
434
|
|
435
|
435
|
RNNUIBarButtonItem* button = (RNNUIBarButtonItem*)[nav.topViewController.navigationItem.rightBarButtonItems objectAtIndex:0];
|
436
|
436
|
NSString* expectedButtonId = @"testId";
|
|
@@ -445,8 +445,8 @@
|
445
|
445
|
|
446
|
446
|
-(void)testLeftButtonsWithTitle_withoutStyle {
|
447
|
447
|
self.options.topBar.leftButtons = @[@{@"id": @"testId", @"text": @"test"}];
|
448
|
|
- __unused RNNNavigationController* nav = [self createNavigationController];
|
449
|
|
- [self.uut viewWillAppear:false];
|
|
448
|
+ self.uut = [[RNNRootViewController alloc] initWithLayoutInfo:nil rootViewCreator:nil eventEmitter:nil presenter:[RNNViewControllerPresenter new] options:self.options defaultOptions:nil];
|
|
449
|
+ RNNNavigationController* nav = [[RNNNavigationController alloc] initWithLayoutInfo:nil childViewControllers:@[self.uut] options:nil defaultOptions:nil presenter:nil];
|
450
|
450
|
|
451
|
451
|
RNNUIBarButtonItem* button = (RNNUIBarButtonItem*)[nav.topViewController.navigationItem.leftBarButtonItems objectAtIndex:0];
|
452
|
452
|
NSString* expectedButtonId = @"testId";
|
|
@@ -460,9 +460,8 @@
|
460
|
460
|
NSNumber* inputColor = @(0xFFFF0000);
|
461
|
461
|
|
462
|
462
|
self.options.topBar.leftButtons = @[@{@"id": @"testId", @"text": @"test", @"enabled": @false, @"buttonColor": inputColor, @"buttonFontSize": @22, @"buttonFontWeight": @"800"}];
|
463
|
|
- __unused RNNNavigationController* nav = [self createNavigationController];
|
464
|
|
-
|
465
|
|
- [self.uut viewWillAppear:false];
|
|
463
|
+ self.uut = [[RNNRootViewController alloc] initWithLayoutInfo:nil rootViewCreator:nil eventEmitter:nil presenter:[RNNViewControllerPresenter new] options:self.options defaultOptions:nil];
|
|
464
|
+ RNNNavigationController* nav = [[RNNNavigationController alloc] initWithLayoutInfo:nil childViewControllers:@[self.uut] options:nil defaultOptions:nil presenter:nil];
|
466
|
465
|
|
467
|
466
|
RNNUIBarButtonItem* button = (RNNUIBarButtonItem*)[nav.topViewController.navigationItem.leftBarButtonItems objectAtIndex:0];
|
468
|
467
|
NSString* expectedButtonId = @"testId";
|