Merge branch 'master' into add-missing-entries-to-spanish-localization

pull/276/head
James Sangalli 7 years ago committed by GitHub
commit b98702d4ff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 12
      Trust/InCoordinator.swift
  2. 4
      TrustTests/Coordinators/InCoordinatorTests.swift

@ -147,9 +147,13 @@ class InCoordinator: Coordinator {
transactionCoordinator.start()
addCoordinator(transactionCoordinator)
let marketplaceController = MarketplaceViewController()
let marketplaceNavigationController = UINavigationController(rootViewController: marketplaceController)
marketplaceController.tabBarItem = UITabBarItem(title: R.string.localizable.aMarketplaceTabbarItemTitle(), image: R.image.tab_marketplace()?.withRenderingMode(.alwaysOriginal), selectedImage: R.image.tab_marketplace())
let tabBarController = TabBarController()
tabBarController.viewControllers = [
transactionCoordinator.navigationController,
marketplaceNavigationController,
]
tabBarController.tabBar.isTranslucent = false
tabBarController.didShake = { [weak self] in
@ -170,11 +174,7 @@ class InCoordinator: Coordinator {
addCoordinator(tokensCoordinator)
tabBarController.viewControllers?.append(tokensCoordinator.navigationController)
}
let marketplaceController = MarketplaceViewController()
let marketplaceNavigationController = UINavigationController(rootViewController: marketplaceController)
marketplaceController.tabBarItem = UITabBarItem(title: R.string.localizable.aMarketplaceTabbarItemTitle(), image: R.image.tab_marketplace()?.withRenderingMode(.alwaysOriginal), selectedImage: R.image.tab_marketplace())
tabBarController.viewControllers?.append(marketplaceNavigationController)
tabBarController.viewControllers?.append(transactionCoordinator.navigationController)
let alphaSettingsCoordinator = SettingsCoordinator(
keystore: keystore,

@ -22,9 +22,9 @@ class InCoordinatorTests: XCTestCase {
XCTAssertNotNil(tabbarController)
XCTAssert(tabbarController?.viewControllers!.count == 4)
XCTAssert((tabbarController?.viewControllers?[0] as? UINavigationController)?.viewControllers[0] is TransactionsViewController)
XCTAssert((tabbarController?.viewControllers?[0] as? UINavigationController)?.viewControllers[0] is MarketplaceViewController)
XCTAssert((tabbarController?.viewControllers?[1] as? UINavigationController)?.viewControllers[0] is TokensViewController)
XCTAssert((tabbarController?.viewControllers?[2] as? UINavigationController)?.viewControllers[0] is MarketplaceViewController)
XCTAssert((tabbarController?.viewControllers?[2] as? UINavigationController)?.viewControllers[0] is TransactionsViewController)
XCTAssert((tabbarController?.viewControllers?[3] as? UINavigationController)?.viewControllers[0] is SettingsViewController)
}

Loading…
Cancel
Save