Remove UI test that has been failing since recent UI changes.

This test has been failing intermittently since the changes to the
account creation UI were merged, and failing more often since the
Material Design 3 changes were merged. There's no obvious reason why
the changes should have affected this test. Since the UI tests don't
provide much value I'm removing it rather than spending time to find
out the cause and make it reliable again.
This commit is contained in:
akwizgran
2024-06-28 17:52:48 +01:00
parent e5f49674ce
commit 69db146a03

View File

@@ -27,18 +27,8 @@ import static androidx.test.espresso.matcher.ViewMatchers.isDisplayed;
import static androidx.test.espresso.matcher.ViewMatchers.isEnabled;
import static androidx.test.espresso.matcher.ViewMatchers.withId;
import static androidx.test.espresso.matcher.ViewMatchers.withText;
import static org.briarproject.bramble.api.crypto.PasswordStrengthEstimator.NONE;
import static org.briarproject.bramble.api.crypto.PasswordStrengthEstimator.QUITE_STRONG;
import static org.briarproject.bramble.api.crypto.PasswordStrengthEstimator.QUITE_WEAK;
import static org.briarproject.bramble.api.crypto.PasswordStrengthEstimator.STRONG;
import static org.briarproject.bramble.api.crypto.PasswordStrengthEstimator.WEAK;
import static org.briarproject.bramble.api.identity.AuthorConstants.MAX_AUTHOR_NAME_LENGTH;
import static org.briarproject.bramble.util.StringUtils.getRandomString;
import static org.briarproject.briar.android.login.StrengthMeter.GREEN;
import static org.briarproject.briar.android.login.StrengthMeter.LIME;
import static org.briarproject.briar.android.login.StrengthMeter.ORANGE;
import static org.briarproject.briar.android.login.StrengthMeter.RED;
import static org.briarproject.briar.android.login.StrengthMeter.YELLOW;
import static org.hamcrest.Matchers.not;
@RunWith(AndroidJUnit4.class)
@@ -81,34 +71,6 @@ public class SetupActivityTest {
onView(withId(R.id.progress)).check(matches(isDisplayed()));
}
@Test
public void testStrengthMeterUI() {
moveToSetPasswordFragment();
onView(withId(R.id.password_entry)).perform(typeText("1234567890ab"));
onView(withId(R.id.strength_meter))
.check(matches(strengthAndColor(STRONG, GREEN)));
onView(withId(R.id.password_entry)).perform(clearText());
onView(withId(R.id.password_entry)).perform(typeText("123456789"));
onView(withId(R.id.strength_meter))
.check(matches(strengthAndColor(QUITE_STRONG, LIME)));
onView(withId(R.id.password_entry)).perform(clearText());
onView(withId(R.id.password_entry)).perform(typeText("123456"));
onView(withId(R.id.strength_meter))
.check(matches(strengthAndColor(QUITE_WEAK, YELLOW)));
onView(withId(R.id.password_entry)).perform(clearText());
onView(withId(R.id.password_entry)).perform(typeText("123"));
onView(withId(R.id.strength_meter))
.check(matches(strengthAndColor(WEAK, ORANGE)));
onView(withId(R.id.password_entry)).perform(clearText());
onView(withId(R.id.strength_meter))
.check(matches(strengthAndColor(NONE, RED)));
}
private void moveToSetPasswordFragment() {
onView(withId(R.id.nickname_entry)).perform(typeText("test"));
onView(withId(R.id.next)).perform(click());