package jp.juggler.subwaytooter import androidx.test.platform.app.InstrumentationRegistry import androidx.test.runner.AndroidJUnit4 import org.junit.Assert import org.junit.Test import org.junit.runner.RunWith // Android instrumentation test は run configuration を編集しないと Empty tests とかいうエラーになります @RunWith(AndroidJUnit4::class) class ExampleInstrumentedTest { @Test fun useAppContext() { // Context of the app under test. val appContext = InstrumentationRegistry.getInstrumentation().targetContext Assert.assertEquals("jp.juggler.subwaytooter", appContext.packageName) } }