@@ -165,7 +165,7 @@ disabledSpec :: SpecWith ((), Application)
165165disabledSpec = describe " test handling of aud claims in JWT when the jwt-aud config is not set" $ do
166166
167167 context " when the audience claim is a string" $ do
168- it " ignores the audience claim and suceeds " $ do
168+ it " fails when it is not empty " $ do
169169 let jwtPayload =
170170 [json |{
171171 "exp": 9999999999,
@@ -175,7 +175,7 @@ disabledSpec = describe "test handling of aud claims in JWT when the jwt-aud con
175175 }|]
176176 auth = authHeaderJWT $ generateJWT jwtPayload
177177 request methodGet " /authors_only" [auth] " "
178- `shouldRespondWith` 200
178+ `shouldRespondWith` 401
179179
180180 it " ignores the audience claim and suceeds when it's empty" $ do
181181 let jwtPayload =
@@ -205,7 +205,7 @@ disabledSpec = describe "test handling of aud claims in JWT when the jwt-aud con
205205
206206
207207 context " when the audience is an array of strings" $ do
208- it " ignores the audience claim and suceeds when it has 1 element" $ do
208+ it " fails it has 1 element" $ do
209209 let jwtPayload = [json |
210210 {
211211 "exp": 9999999999,
@@ -215,9 +215,9 @@ disabledSpec = describe "test handling of aud claims in JWT when the jwt-aud con
215215 }|]
216216 auth = authHeaderJWT $ generateJWT jwtPayload
217217 request methodGet " /authors_only" [auth] " "
218- `shouldRespondWith` 200
218+ `shouldRespondWith` 401
219219
220- it " ignores the audience claim and suceeds when it has more than 1 element" $ do
220+ it " fails when it has more than 1 element" $ do
221221 let jwtPayload = [json |
222222 {
223223 "exp": 9999999999,
@@ -227,7 +227,7 @@ disabledSpec = describe "test handling of aud claims in JWT when the jwt-aud con
227227 }|]
228228 auth = authHeaderJWT $ generateJWT jwtPayload
229229 request methodGet " /authors_only" [auth] " "
230- `shouldRespondWith` 200
230+ `shouldRespondWith` 401
231231
232232 it " ignores the audience claim and suceeds when it's empty" $ do
233233 let jwtPayload = [json |
0 commit comments