From a79c718705a391147919a75aae4d9a26b63d9395 Mon Sep 17 00:00:00 2001 From: Mark Wotton Date: Wed, 4 May 2016 17:37:12 -0400 Subject: [PATCH] fix test --- servant-client/test/Servant/ClientSpec.hs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/servant-client/test/Servant/ClientSpec.hs b/servant-client/test/Servant/ClientSpec.hs index bf37d482..f45e2b17 100644 --- a/servant-client/test/Servant/ClientSpec.hs +++ b/servant-client/test/Servant/ClientSpec.hs @@ -395,10 +395,9 @@ genAuthSpec = beforeAll (startWaiApp genAuthServer) $ afterAll endWaiApp $ do (left show <$> runExceptT (getProtected authRequest manager baseUrl)) `shouldReturn` Right alice it "Also works for more complicated apis" $ \(_, baseUrl) -> do - let (getProtected :<|> getOtherProtected) = client genAuthAPI2 let authRequest = mkAuthenticateReq () (\_ req -> SCR.addHeader "AuthHeader" ("cool" :: String) req) - (left show <$> runExceptT (getProtected authRequest manager baseUrl)) `shouldReturn` Right alice - + let (getProtected :<|> getOtherProtected) = client genAuthAPI2 $ authRequest + (left show <$> runExceptT (getProtected manager baseUrl)) `shouldReturn` Right alice context "Authentication is rejected when requests are not authenticated properly" $ do