Last active
January 26, 2021 14:25
-
-
Save Kdan/48ca1aab20295494f61f5a2dbc128142 to your computer and use it in GitHub Desktop.
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
func testCheckAnswerTrue() { | |
b.validateAnswerResponse = true | |
a.checkAnswer() | |
XCTAssertTrue(a.hasAnswer) | |
// The `validateAnswer()` function should be called exactly once. | |
let call = b.calls(with: .validateAnswer) | |
XCTAssertNotNil(call) | |
XCTAssertEqual(call?.numberOfCalls, 1) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment