From ceb5711de61784fbedebc1c6a99de0a04525d526 Mon Sep 17 00:00:00 2001 From: Albin Date: Thu, 16 Nov 2023 13:50:09 +0100 Subject: [PATCH] Add login input test tag --- .../kotlin/net/mullvad/mullvadvpn/compose/screen/LoginScreen.kt | 2 ++ .../mullvad/mullvadvpn/compose/test/ComposeTestTagConstants.kt | 1 + 2 files changed, 3 insertions(+) diff --git a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/LoginScreen.kt b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/LoginScreen.kt index 4789dc33ec0d..e7d6e40a60c6 100644 --- a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/LoginScreen.kt +++ b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/screen/LoginScreen.kt @@ -59,6 +59,7 @@ import net.mullvad.mullvadvpn.compose.state.LoginError import net.mullvad.mullvadvpn.compose.state.LoginState import net.mullvad.mullvadvpn.compose.state.LoginState.* import net.mullvad.mullvadvpn.compose.state.LoginUiState +import net.mullvad.mullvadvpn.compose.test.LOGIN_INPUT_TEST_TAG import net.mullvad.mullvadvpn.compose.test.LOGIN_TITLE_TEST_TAG import net.mullvad.mullvadvpn.compose.textfield.mullvadWhiteTextFieldColors import net.mullvad.mullvadvpn.compose.util.accountTokenVisualTransformation @@ -183,6 +184,7 @@ private fun LoginContent( right = FocusRequester.Cancel } .fillMaxWidth() + .testTag(LOGIN_INPUT_TEST_TAG) .let { if (!expandedDropdown || uiState.lastUsedAccount == null) { it.clip(MaterialTheme.shapes.small) diff --git a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/test/ComposeTestTagConstants.kt b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/test/ComposeTestTagConstants.kt index 14a42403e179..01d434a117d0 100644 --- a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/test/ComposeTestTagConstants.kt +++ b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/compose/test/ComposeTestTagConstants.kt @@ -30,3 +30,4 @@ const val NOTIFICATION_BANNER_ACTION = "notification_banner_action" const val PLAY_PAYMENT_INFO_ICON_TEST_TAG = "play_payment_info_icon_test_tag" const val LOGIN_TITLE_TEST_TAG = "login_title_test_tag" +const val LOGIN_INPUT_TEST_TAG = "login_input_test_tag"