Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
varshith257 committed Sep 29, 2024
1 parent 1809611 commit a8006d6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions zio-http/jvm/src/test/scala/zio/http/ServerSpec.scala
Original file line number Diff line number Diff line change
Expand Up @@ -524,15 +524,15 @@ object ServerSpec extends RoutesRunnableSpec {

val requestWithoutHost = Request.get("/test")

val res = app.deploy.run(requestWithoutHost).map(_.status)
val res = app.deploy.runZIO(requestWithoutHost).map(_.status)
assertZIO(res)(equalTo(Status.BadRequest))
} +
test("should return 200 OK if Host header is present") {
val route = Method.GET / "test" -> Handler.ok
val app = Routes(route)
val requestWithHost = Request.get("/test").addHeader(Header.Host("localhost"))

val res = app.deploy.run(requestWithHost).map(_.status)
val res = app.deploy.runZIO(requestWithHost).map(_.status)
assertZIO(res)(equalTo(Status.Ok))
}
}
Expand Down

0 comments on commit a8006d6

Please sign in to comment.