From 09f8c1a2a8c9e74cb4c6a923f09596a176e397ff Mon Sep 17 00:00:00 2001 From: Brian Demers Date: Thu, 15 Jun 2017 13:04:13 -0400 Subject: [PATCH] Adds a simple basic auth test for the /me endpoint --- src/main/groovy/com/stormpath/tck/me/MeIT.groovy | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/main/groovy/com/stormpath/tck/me/MeIT.groovy b/src/main/groovy/com/stormpath/tck/me/MeIT.groovy index 81457be..bbacc75 100644 --- a/src/main/groovy/com/stormpath/tck/me/MeIT.groovy +++ b/src/main/groovy/com/stormpath/tck/me/MeIT.groovy @@ -189,6 +189,20 @@ class MeIT extends AbstractIT { .spec(AccountResponseSpec.matchesAccount(account)) } + /** + * Test that Basic with user/password works against /me + */ + @Test(groups=["v100", "json"]) + void meWithBasicAuthReturnsJsonUser() throws Exception { + + given() + .auth().preemptive().basic(account.username, account.password) + .when() + .get(MeRoute) + .then() + .spec(AccountResponseSpec.matchesAccount(account)) + } + /** * We should not have linked resources. * @see https://github.com/stormpath/stormpath-framework-tck/issues/64