30 lines
783 B
Swift
30 lines
783 B
Swift
import XCTest
|
|
import AutoCat2
|
|
|
|
class ApiTests: XCTestCase {
|
|
|
|
private var api: Api!
|
|
|
|
override func setUpWithError() throws {
|
|
let sessionConfig = URLSessionConfiguration.default
|
|
let session = URLSession(configuration: sessionConfig)
|
|
self.api = Api(session: session)
|
|
}
|
|
|
|
override func tearDownWithError() throws {
|
|
// Put teardown code here. This method is called after the invocation of each test method in the class.
|
|
}
|
|
|
|
func testLogin() async throws {
|
|
let user = try await self.api.login()
|
|
}
|
|
|
|
// func testPerformanceExample() throws {
|
|
// // This is an example of a performance test case.
|
|
// self.measure {
|
|
// // Put the code you want to measure the time of here.
|
|
// }
|
|
// }
|
|
|
|
}
|