Use resource processor for Settings
Bug: 293810334 Test: m Settings Test: robotests Change-Id: Ie515e137648eddfdfcab5e8095f5be99721d9e1b
This commit is contained in:
@@ -35,21 +35,29 @@ class RemoteAuthEnrollFinishTest {
|
||||
|
||||
@Test
|
||||
fun testRemoteAuthenticatorEnrollFinish_hasHeader() {
|
||||
launchFragmentInContainer<RemoteAuthEnrollFinish>(Bundle(), R.style.SudThemeGlif)
|
||||
.onFragment {
|
||||
assertThat((it.view as GlifLayout).headerText)
|
||||
.isEqualTo(mContext.getString(
|
||||
R.string.security_settings_remoteauth_enroll_finish_title))
|
||||
}
|
||||
launchFragmentInContainer<RemoteAuthEnrollFinish>(
|
||||
Bundle(),
|
||||
com.google.android.setupdesign.R.style.SudThemeGlif,
|
||||
).onFragment {
|
||||
assertThat((it.view as GlifLayout).headerText)
|
||||
.isEqualTo(
|
||||
mContext.getString(R.string.security_settings_remoteauth_enroll_finish_title)
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
fun testRemoteAuthenticatorEnrollFinish_hasDescription() {
|
||||
launchFragmentInContainer<RemoteAuthEnrollFinish>(Bundle(), R.style.SudThemeGlif)
|
||||
.onFragment {
|
||||
assertThat((it.view as GlifLayout).descriptionText)
|
||||
.isEqualTo(mContext.getString(
|
||||
R.string.security_settings_remoteauth_enroll_finish_description))
|
||||
}
|
||||
launchFragmentInContainer<RemoteAuthEnrollFinish>(
|
||||
Bundle(),
|
||||
com.google.android.setupdesign.R.style.SudThemeGlif,
|
||||
).onFragment {
|
||||
assertThat((it.view as GlifLayout).descriptionText)
|
||||
.isEqualTo(
|
||||
mContext.getString(
|
||||
R.string.security_settings_remoteauth_enroll_finish_description
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -30,23 +30,31 @@ import org.robolectric.RobolectricTestRunner
|
||||
|
||||
@RunWith(RobolectricTestRunner::class)
|
||||
class RemoteAuthEnrollIntroductionTest {
|
||||
private var mContext : Context = ApplicationProvider.getApplicationContext()
|
||||
private var mContext: Context = ApplicationProvider.getApplicationContext()
|
||||
|
||||
@Test
|
||||
fun testRemoteAuthenticatorEnrollIntroduction_hasHeader() {
|
||||
launchFragmentInContainer<RemoteAuthEnrollIntroduction>(Bundle(), R.style.SudThemeGlif)
|
||||
.onFragment {
|
||||
assertThat((it.view as GlifLayout).headerText)
|
||||
.isEqualTo(mContext.getString(R.string.security_settings_remoteauth_enroll_introduction_title))
|
||||
}
|
||||
launchFragmentInContainer<RemoteAuthEnrollIntroduction>(
|
||||
Bundle(),
|
||||
com.google.android.setupdesign.R.style.SudThemeGlif,
|
||||
).onFragment {
|
||||
assertThat((it.view as GlifLayout).headerText)
|
||||
.isEqualTo(mContext.getString(R.string.security_settings_remoteauth_enroll_introduction_title))
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
fun testRemoteAuthenticatorEnrollIntroduction_hasDescription() {
|
||||
launchFragmentInContainer<RemoteAuthEnrollIntroduction>(Bundle(), R.style.SudThemeGlif)
|
||||
.onFragment {
|
||||
assertThat((it.view as GlifLayout).descriptionText)
|
||||
.isEqualTo(mContext.getString(R.string.security_settings_remoteauth_enroll_introduction_message))
|
||||
}
|
||||
launchFragmentInContainer<RemoteAuthEnrollIntroduction>(
|
||||
Bundle(),
|
||||
com.google.android.setupdesign.R.style.SudThemeGlif,
|
||||
).onFragment {
|
||||
assertThat((it.view as GlifLayout).descriptionText)
|
||||
.isEqualTo(
|
||||
mContext.getString(
|
||||
R.string.security_settings_remoteauth_enroll_introduction_message
|
||||
)
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user