Created
March 17, 2018 13:30
-
-
Save alouanemed/1064483f554a93d6ed526680ce15bcfc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@get:Rule | |
val activityTestRule = object : IntentsTestRule<MainActivity>(MainActivity::class.java, true, | |
true) { | |
override fun beforeActivityLaunched() { | |
super.beforeActivityLaunched() | |
var myApp = InstrumentationRegistry.getTargetContext().applicationContext as HarvestOrderApp | |
myApp.dispatchingActivityInjector = MockAndroidInjectorFragment<BuyerOrdersListFragment, MainActivity> { | |
this.mPresenterFactory = ordersPresenterFactors | |
} | |
myApp.dispatchingActivityInjector = MockAndroidInjectorFragment<BuyerAddressesFragment, UiContainerActivity> { | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment