test: add test ids to the contact form's name and email fields

This commit is contained in:
Linus Rath
2026-10-22 22:04:28 +02:00
parent dde504f825
commit 33fc33910a
+3
View File
@@ -1254,6 +1254,7 @@ export default function ContactFormScreen() {
style={styles.input}
placeholder={t('contacts.form.given_name', 'First name')}
ref={givenRef}
testID="contact-first-name"
returnKeyType="next"
blurOnSubmit={false}
onSubmitEditing={() => middleRef.current?.focus()}
@@ -1280,6 +1281,7 @@ export default function ContactFormScreen() {
style={styles.input}
placeholder={t('contacts.form.surname', 'Last name')}
ref={surnameRef}
testID="contact-last-name"
returnKeyType="next"
blurOnSubmit={false}
onSubmitEditing={() => fullRef.current?.focus()}
@@ -1347,6 +1349,7 @@ export default function ContactFormScreen() {
style={styles.input}
placeholder={t('contacts.form.email_placeholder', 'email@example.com')}
ref={i === 0 ? firstEmailRef : undefined}
testID={`contact-email-${i}`}
placeholderTextColor={c.textMuted}
keyboardType="email-address"
autoCapitalize="none"