Revision control

1
/* This Source Code Form is subject to the terms of the Mozilla Public
2
* License, v. 2.0. If a copy of the MPL was not distributed with this
3
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
4
5
import Shared
6
import XCTest
7
8
// Trivial test for using Result.
9
class ResultTests: XCTestCase {
10
func testResult() {
11
let r = Maybe<Int>(success: 5)
12
if let i = r.successValue {
13
XCTAssertEqual(5, i)
14
} else {
15
XCTFail("Expected success.")
16
}
17
}
18
}