https://kotlinlang.org logo
#android
Title
# android
d

dave08

02/11/2018, 5:08 PM
Anybody get
Copy code
Started running tests
Test running failed: Instrumentation run failed due to 'java.lang.IllegalAccessError'
Empty test suite.
in espresso tests? Maybe I have something wrong here?
Copy code
@RunWith(AndroidJUnit4::class)
class NewWazeTest {
	@get:Rule
	val rule = ActivityTestRule<FirstLoginActivity>(FirstLoginActivity::class.java)

	@get:Rule
	val intentsTestRule = IntentsTestRule<CheckServerActivity>(CheckServerActivity::class.java)
d

Daniel

02/11/2018, 5:12 PM
I must expose the rule as a @JvmField to make the tests work, no luck so far with @get:Rule
d

dave08

02/11/2018, 5:18 PM
That's the error you get if not? Or I have two issues here?
3 Views