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 XCTest | |
@testable import YourProjectModule | |
class ViewControllerTest: XCTestCase { | |
var systemUnderTest: ViewController! | |
override func setUp() { | |
super.setUp() |
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
// | |
// TEST CODE | |
import XCTest | |
@testable import to | |
class JSONReaderTest: XCTestCase { | |
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
// Example of an asynchronous unit test | |
func testUserLogin() { | |
let readyExpectation = expectationWithDescription("ready") | |
User.loginWithUsername("kris@bla.org", password: "blah") { (isSuccess) -> Void in | |
let expectedLoginSuccessStatus = true |
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 XCTest | |
@testable import YourAppTargetname | |
class SideMenuViewControllerTest: XCTestCase { | |
var viewControllerUnderTest: SideMenuViewController! | |
override func setUp() { | |
super.setUp() | |