Last active
September 2, 2017 21:33
-
-
Save rachidcalazans/e59c5aa3122015abda7d39086d172fdd to your computer and use it in GitHub Desktop.
Helper Test file for the Post - better-setups-on-swift-tests
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Foundation | |
struct Action { | |
let block: () -> () | |
func call() { | |
block() | |
} | |
} | |
func execute(action: Action, _ setup: () -> () = {} ) { | |
setup() | |
action.block() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment