aboutsummaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
authorSatya Boora <sboora@users.noreply.github.com>2018-04-10 12:33:02 -0700
committerGitHub <noreply@github.com>2018-04-10 12:33:02 -0700
commit4cfa6a09c6f6692f5513ff6e31f261a020d07068 (patch)
tree07b1067771f0be135a2c4511e701be22244df1df /src/test
parentf7c3184c0932db90eaae266e1518f94076ce5912 (diff)
downloaddriver-core-4cfa6a09c6f6692f5513ff6e31f261a020d07068.tar.gz
driver-core-4cfa6a09c6f6692f5513ff6e31f261a020d07068.tar.bz2
driver-core-4cfa6a09c6f6692f5513ff6e31f261a020d07068.zip
Use AuthenticationFailedRejection to send 401 back to the client (#151)v1.8.20
Diffstat (limited to 'src/test')
-rw-r--r--src/test/scala/xyz/driver/core/AuthTest.scala3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/test/scala/xyz/driver/core/AuthTest.scala b/src/test/scala/xyz/driver/core/AuthTest.scala
index 6e5862a..a7707aa 100644
--- a/src/test/scala/xyz/driver/core/AuthTest.scala
+++ b/src/test/scala/xyz/driver/core/AuthTest.scala
@@ -79,7 +79,8 @@ class AuthTest extends FlatSpec with Matchers with ScalatestRouteTest {
} ~>
check {
// handled shouldBe false
- rejections should contain(ValidationRejection("Wasn't able to find authenticated user for the token provided"))
+ val challenge = HttpChallenges.basic("Failed to authenticate user")
+ rejections should contain(AuthenticationFailedRejection(CredentialsRejected, challenge))
}
}