17 lines
396 B
Swift
17 lines
396 B
Swift
@testable import App
|
|
import XCTVapor
|
|
|
|
final class AppTests: XCTestCase {
|
|
|
|
func testHelloWorld() throws {
|
|
let app = Application(.testing)
|
|
defer { app.shutdown() }
|
|
try configure(app)
|
|
|
|
try app.test(.GET, "status") { res in
|
|
XCTAssertEqual(res.status, .ok)
|
|
XCTAssertEqual(res.body.getData(at: 0, length: 1), Data([3]))
|
|
}
|
|
}
|
|
}
|