Skip to content

Instantly share code, notes, and snippets.

@khalidr
Last active January 23, 2016 18:41
Show Gist options
  • Save khalidr/9b2b0f340a07b03cedc5 to your computer and use it in GitHub Desktop.
Save khalidr/9b2b0f340a07b03cedc5 to your computer and use it in GitHub Desktop.
Complete With BadRequest (spray 1.3.3)
val r = {
path("foo"){
get{
complete(StatusCodes.BadRequest)
}
}
}
Get("/foo") ~> r ~> check{
println(response.status) // returns "400 Bad Request"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment