From e126cdf9187a3c06bf6aca24003e0eb9c98c898b Mon Sep 17 00:00:00 2001 From: Marco Zocca Date: Tue, 31 Oct 2023 08:36:19 +0100 Subject: [PATCH] fix test app imports --- README.md | 2 +- ms-auth/src/Network/OAuth2/Provider/AzureAD.hs | 2 ++ ms-azure-api-test/app/Main.hs | 6 +++--- ms-azure-api-test/ms-azure-api-test.cabal | 3 +-- ms-graph-api-test/ms-graph-api-test.cabal | 3 +-- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 28a22e9..4dba83c 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ ## Introduction -We provide separate libraries for authentication (`ms-auth`), Graph (`ms-graph-api`) and Azure (`ms-azure-api`) since they cater to different use cases; a typical use case will need to import `ms-auth` as well as the API binding they need. +We provide separate libraries for authentication (`ms-auth`), Graph (`ms-graph-api`) and Azure (`ms-azure-api`) since they cater to different use cases. Both the Graph and Azure SDKs import `ms-auth`. ## Examples diff --git a/ms-auth/src/Network/OAuth2/Provider/AzureAD.hs b/ms-auth/src/Network/OAuth2/Provider/AzureAD.hs index 4953029..9e1c15c 100644 --- a/ms-auth/src/Network/OAuth2/Provider/AzureAD.hs +++ b/ms-auth/src/Network/OAuth2/Provider/AzureAD.hs @@ -25,6 +25,8 @@ module Network.OAuth2.Provider.AzureAD ( , azureOAuthADApp -- * Exceptions , AzureADException(..) + -- * Types + , Idp(..), IdpApplication(..) ) where -- import Data.String (IsString(..)) diff --git a/ms-azure-api-test/app/Main.hs b/ms-azure-api-test/app/Main.hs index d1b6b1c..ab4fbc0 100644 --- a/ms-azure-api-test/app/Main.hs +++ b/ms-azure-api-test/app/Main.hs @@ -13,13 +13,13 @@ import Data.Aeson.Encode.Pretty (encodePretty) import qualified Data.ByteString.Lazy.Char8 as LBS8 (pack, unpack, putStrLn) -- dotenv-micro import DotEnv.Micro (loadDotEnv) --- hoauth2 -import Network.OAuth.OAuth2 (OAuth2Token(..), AccessToken) -import Network.OAuth2.Experiment (IdpApplication, GrantTypeFlow(..)) -- http-client import Network.HTTP.Client (Manager) -- http-types import Network.HTTP.Types.Status (status200) +-- ms-auth +import MSAuth (OAuth2Token(..), AccessToken) +import Network.OAuth2.Provider.AzureAD (IdpApplication, GrantTypeFlow(..)) -- req import Network.HTTP.Req (HttpConfig) -- scotty diff --git a/ms-azure-api-test/ms-azure-api-test.cabal b/ms-azure-api-test/ms-azure-api-test.cabal index 962981c..b3d235f 100644 --- a/ms-azure-api-test/ms-azure-api-test.cabal +++ b/ms-azure-api-test/ms-azure-api-test.cabal @@ -33,12 +33,11 @@ executable ms-azure-api-test , bytestring , directory >= 1.3.6.2 , dotenv-micro == 0.1.0.1 - , hoauth2 == 2.6.0 , http-client , http-client-tls >= 0.3 , http-types , ms-azure-api-test - , ms-auth + , ms-auth >= 0.5 , ms-azure-api , req , scotty diff --git a/ms-graph-api-test/ms-graph-api-test.cabal b/ms-graph-api-test/ms-graph-api-test.cabal index e5926a1..0fbc9db 100644 --- a/ms-graph-api-test/ms-graph-api-test.cabal +++ b/ms-graph-api-test/ms-graph-api-test.cabal @@ -33,10 +33,9 @@ executable ms-graph-api-test , bytestring , directory >= 1.3.6.2 , dotenv-micro == 0.1.0.1 - , hoauth2 == 2.6.0 , http-client , http-client-tls >= 0.3 - , ms-auth >= 0.4 + , ms-auth >= 0.5 , ms-graph-api , ms-graph-api-test , req