Skip to content

Instantly share code, notes, and snippets.

@polac24
Created March 31, 2019 17:59
Show Gist options
  • Save polac24/9977effabc5c4593bd2eaa1e2df9f1df to your computer and use it in GitHub Desktop.
Save polac24/9977effabc5c4593bd2eaa1e2df9f1df to your computer and use it in GitHub Desktop.
// compareAction: ((Int,Int)) -> CompareResult
lazy var compareAction = stub(of: compare)
func compare(_ element1:Int, _ element2:Int) -> CompareResult {
return compareAction((element1, element2))
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment