Skip to content

Commit

Permalink
Follow with the existing tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
sidepelican committed Dec 3, 2023
1 parent 23680f5 commit ac3d729
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 52 deletions.
52 changes: 0 additions & 52 deletions Tests/HummingbirdFoundationTests/FileMiddlewareTests.swift

This file was deleted.

7 changes: 7 additions & 0 deletions Tests/HummingbirdFoundationTests/FilesTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -295,9 +295,16 @@ class HummingbirdFilesTests: XCTestCase {
try app.XCTStart()
defer { app.XCTStop() }

try app.XCTExecute(uri: "/index.html", method: .GET) { response in
var body = try XCTUnwrap(response.body)
XCTAssertEqual(body.readString(length: body.readableBytes), text)
XCTAssertEqual(response.headers.first(name: "content-type"), "text/html")
}

try app.XCTExecute(uri: "/", method: .GET) { response in
var body = try XCTUnwrap(response.body)
XCTAssertEqual(body.readString(length: body.readableBytes), text)
XCTAssertEqual(response.headers.first(name: "content-type"), "text/html")
}
}

Expand Down

0 comments on commit ac3d729

Please sign in to comment.