I have the following test, where the test name is with space and backtick for my instrumental test
@RunWith(AndroidJUnit4::class)
class MyTestClass {
@Rule
@JvmField
var activityRule: ActivityTestRule<MainActivity> = ActivityTestRule(MainActivity::class.java)
@Test
fun `My space name testing`() {
// Some test
}
}
However when running it, it can't be executed (i.e. No test were found)
Checking on it, I saw this linting error on the test function name..
This inspection reports identifiers in android projects which are not accepted by the Android runtime (for example, method names containing spaces)
When I rename my test function from My space name testing
to mySpaceNameTesting
, the test run.
Is it really that AndroidJunit4 runtime can't support test function name with spaces?