Skip to content

Instantly share code, notes, and snippets.

@candostdagdeviren
Created December 3, 2018 12:35
Show Gist options
  • Save candostdagdeviren/a14046e9c02d9a98899deeb179872726 to your computer and use it in GitHub Desktop.
Save candostdagdeviren/a14046e9c02d9a98899deeb179872726 to your computer and use it in GitHub Desktop.
Swift Post Testability Example Code
protocol URLOpening {
func canOpenURL(_ url: URL) -> Bool
func open(_ url: URL,
options: [UIApplication.OpenExternalURLOptionsKey : Any],
completionHandler completion: ((Bool) -> Void)?)
}
extension UIApplication: URLOpening {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment