use of com.android.settings.password.ChooseLockPattern.ChooseLockPatternFragment in project android_packages_apps_Settings by omnirom.
the class ChooseLockPatternTest method assertThat_chooseLockIconChanged_WhenFingerprintExtraSet.
@Test
public void assertThat_chooseLockIconChanged_WhenFingerprintExtraSet() {
ChooseLockPattern activity = createActivity(true);
ChooseLockPatternFragment fragment = (ChooseLockPatternFragment) activity.getFragmentManager().findFragmentById(R.id.main_content);
ShadowDrawable drawable = Shadows.shadowOf(((GlifLayout) fragment.getView()).getIcon());
assertThat(drawable.getCreatedFromResId()).isEqualTo(R.drawable.ic_fingerprint_header);
}
use of com.android.settings.password.ChooseLockPattern.ChooseLockPatternFragment in project android_packages_apps_Settings by crdroidandroid.
the class ChooseLockPatternTest method assertThat_chooseLockIconChanged_WhenFingerprintExtraSet.
@Test
public void assertThat_chooseLockIconChanged_WhenFingerprintExtraSet() {
ChooseLockPattern activity = createActivity(true);
ChooseLockPatternFragment fragment = (ChooseLockPatternFragment) activity.getFragmentManager().findFragmentById(R.id.main_content);
ShadowDrawable drawable = Shadows.shadowOf(((GlifLayout) fragment.getView()).getIcon());
assertThat(drawable.getCreatedFromResId()).isEqualTo(R.drawable.ic_fingerprint_header);
}
use of com.android.settings.password.ChooseLockPattern.ChooseLockPatternFragment in project Resurrection_packages_apps_Settings by ResurrectionRemix.
the class SetupChooseLockPatternTest method createActivity_enterPattern_clearButtonShouldBeShown.
@Test
public void createActivity_enterPattern_clearButtonShouldBeShown() {
ChooseLockPatternFragment fragment = findFragment(mActivity);
PartnerCustomizationLayout layout = mActivity.findViewById(R.id.setup_wizard_layout);
final Button skipOrClearButton = layout.getMixin(FooterBarMixin.class).getSecondaryButtonView();
assertThat(skipOrClearButton.isEnabled()).isTrue();
assertThat(skipOrClearButton.getVisibility()).isEqualTo(View.VISIBLE);
assertThat(skipOrClearButton.getText()).isEqualTo(application.getString(R.string.skip_label));
enterPattern();
assertThat(skipOrClearButton.isEnabled()).isTrue();
assertThat(skipOrClearButton.getVisibility()).isEqualTo(View.VISIBLE);
assertThat(skipOrClearButton.getText()).isEqualTo(application.getString(R.string.lockpattern_retry_button_text));
}
use of com.android.settings.password.ChooseLockPattern.ChooseLockPatternFragment in project Resurrection_packages_apps_Settings by ResurrectionRemix.
the class ChooseLockPatternTest method smallScreens_shouldHideIcon.
@Config(qualifiers = "sw300dp")
@Test
public void smallScreens_shouldHideIcon() {
ChooseLockPattern activity = createActivity(true);
ChooseLockPatternFragment fragment = (ChooseLockPatternFragment) activity.getSupportFragmentManager().findFragmentById(R.id.main_content);
View iconView = fragment.getView().findViewById(R.id.sud_layout_icon);
assertThat(iconView.getVisibility()).isEqualTo(View.GONE);
}
use of com.android.settings.password.ChooseLockPattern.ChooseLockPatternFragment in project android_packages_apps_Settings by LineageOS.
the class ChooseLockPatternTest method assertThat_chooseLockIconChanged_WhenFingerprintExtraSet.
@Test
public void assertThat_chooseLockIconChanged_WhenFingerprintExtraSet() {
ChooseLockPattern activity = createActivity(true);
ChooseLockPatternFragment fragment = (ChooseLockPatternFragment) activity.getFragmentManager().findFragmentById(R.id.main_content);
ShadowDrawable drawable = Shadows.shadowOf(((GlifLayout) fragment.getView()).getIcon());
assertThat(drawable.getCreatedFromResId()).isEqualTo(R.drawable.ic_fingerprint_header);
}
Aggregations