title: How to write UI tests covering login with Facebook in Xcode?
body: <p>I would like to write a UI test in Xcode covering a login with <a href="https://cocoapods.org/pods/FBSDKLoginKit" rel="nofollow noreferrer"><code>FBDSKLoginKit</code></a>.</p>
  
  <p>However, <a href="https://developers.facebook.com/blog/post/2015/10/29/Facebook-Login-iOS9/" rel="nofollow noreferrer">Facebook iOS SDK uses <code>SFSafariViewController</code></a> presented to the user in order to authenticate her and unfortunately, <a href="https://stackoverflow.com/questions/32763010/any-way-to-automate-sfsafariviewcontroller-in-ui-tests">there's no way how to interact with <code>SFSafariViewController</code> in UI tests in Xcode 7</a>.</p>
  
  <p><em>Any ideas how to test the facebook login without interacting with <code>SFSafariViewController</code>?</em></p>