Hello,
I am wondering if anyone else has seen this bug:
- Create a multiline TextField like so:
TextField("a string", text: $myDataStore.placeholder, axis: .vertical)
.accessibilityIdentifier("placeholder")
.multilineTextAlignment(.leading)
.lineLimit(...3)
.textFieldStyle(CustomTextFieldStyle(text: $myDataStore.placeholder, hasErrors: myDataStore.placeholder.isEmpty))
-
Then create a UITest that accesses it.
let multilineTextField = app.textViews["placeholder"] // note that multiline textFields can only be accessed as textVIEWS, not textFIELDS. They simply do not appear under po.textFields let exists = multilineTextField.waitForExistence(timeout: 3) XCTAssertTrue(exists, "The field did not appear in time.") multilineTextField.tap() // everything is fine up to here //BUG: multiline textfields will not tap into keyboard on larger device types like the iPhone 15, but they will on SEs. multilineTextField.typeText("A Test") // fails on anything other than an SE, "Neither element nor any descendant has keyboard focus"
What is happening here?