Starting on 10/20/17, did something change regarding the iOS simulators that are used for the Xcode Test step? All of my test jobs suddenly started failing with this error:
“Neither element nor any descendant has keyboard focus”
This error occurs when XCTest / simulator cannot access the keyboard when attempting to type some value into a text field element. Until now (for around 6 months or so). In order to prevent this from happening, you must go to (iOS Simulator menu) Hardware > Keyboard > then disable “Connect Hardware Keyboard”.
As this is a CI service , I was accomplishing this remotely by running a script before running the Xcode Test step:
defaults write com.apple.iphonesimulator ConnectHardwareKeyboard -bool false
This was working beautifully, but for some reason this is no longer accomplishing the desired effect. I honestly have no idea how other people have been getting around this without running this pre-test script, when using Xcode UI Tests.
Any expedient help would be really appreciated. Thanks a lot.