Created
August 24, 2018 13:36
-
-
Save Gocrazy/2628137d204e63b6f52d61d16db04383 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 | |
| import XCTest | |
| struct TodoItem { | |
| let title: String | |
| let dueBy: Date? | |
| init(title: String) { | |
| self.title = title | |
| self.dueBy = nil | |
| } | |
| } | |
| class TodoTests: XCTestCase { | |
| override func setUp() { | |
| super.setUp() | |
| } | |
| override func tearDown() { | |
| super.tearDown() | |
| } | |
| func testTodo() { | |
| let taskTitle = "finish laundry" | |
| let todo = TodoItem(title: taskTitle) | |
| XCTAssertEqual(todo.title, taskTitle) | |
| } | |
| } | |
| TodoTests.defaultTestSuite.run() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment