2
0
mirror of https://github.com/fork-maintainers/iceraven-browser synced 2024-11-03 23:15:31 +00:00

[fenix] Bug 1814082 - New verifyAutofillAddressSectionTest UI test

This commit is contained in:
AndiAJ 2023-02-03 13:50:48 +02:00 committed by mergify[bot]
parent ee81a71701
commit 1ac216a676
2 changed files with 39 additions and 3 deletions

View File

@ -366,4 +366,41 @@ class AddressAutofillTest {
verifyManuallyFilledAddress("Ap. 07")
}
}
@Test
fun verifyAutofillAddressSectionTest() {
homeScreen {
}.openThreeDotMenu {
}.openSettings {
}.openAutofillSubMenu {
verifyAddressAutofillSection(true, false)
clickAddAddressButton()
fillAndSaveAddress(
"Mozilla",
"Fenix",
"Firefox",
"Harrison Street",
"San Francisco",
"Alaska",
"94105",
"United States",
"555-5555",
"foo@bar.com",
)
verifyAddressAutofillSection(true, true)
clickManageAddressesButton()
verifyManageAddressesSection(
"Mozilla",
"Fenix",
"Firefox",
"Harrison Street",
"San Francisco",
"Alaska",
"94105",
"US",
"555-5555",
"foo@bar.com",
)
}
}
}

View File

@ -208,21 +208,20 @@ class SettingsSubMenuAutofillRobot {
emailAddress: String,
) {
firstNameTextInput.waitForExists(waitingTime)
mDevice.pressBack()
firstNameTextInput.setText(firstName)
middleNameTextInput.setText(middleName)
lastNameTextInput.setText(lastName)
streetAddressTextInput.setText(streetAddress)
scrollToElementByText(getStringResource(R.string.addresses_city))
cityTextInput.setText(city)
subRegionDropDown.click()
clickSubRegionOption(state)
zipCodeTextInput.setText(zipCode)
countryDropDown.click()
clickCountryOption(country)
scrollToElementByText(getStringResource(R.string.addresses_phone))
scrollToElementByText(getStringResource(R.string.addresses_save_button))
phoneTextInput.setText(phoneNumber)
emailTextInput.setText(emailAddress)
scrollToElementByText(getStringResource(R.string.addresses_save_button))
saveButton.click()
manageAddressesButton.waitForExists(waitingTime)
}