I'm opening a SFSafariViewController and can't find the "Done" Button to leave Safari again.
Also if I try to solve it with a swipeRight XCode creates code that it can't use in a test afterwards
let element = app.children(matching: .window).element(boundBy: 0).children(matching: .other).element.children(matching: .other).element.children(matching: .other).element(boundBy: 2)
element.swipeRight()
Any idea how to dismiss SFSafariViewController? (I don't need access to elements in the browser).
This worked for me:
The waitUntilElementExists I think its the key to making it work, I wait 60 seconds tops.