diff --git a/libs/hscim/hscim.cabal b/libs/hscim/hscim.cabal index e5afdc50875..870c476dbcf 100644 --- a/libs/hscim/hscim.cabal +++ b/libs/hscim/hscim.cabal @@ -7,7 +7,7 @@ cabal-version: 1.12 -- hash: b8d0589f22bc168d16fa3a2b2800d9cc3b14b4d94bb911fe973ccf2a2025e5e5 name: hscim -version: 0.3.4 +version: 0.3.5 synopsis: hscim json schema and server implementation description: The README file will answer all the questions you might have category: Web diff --git a/libs/hscim/package.yaml b/libs/hscim/package.yaml index 7a6e3bc0d19..1bd19369caa 100644 --- a/libs/hscim/package.yaml +++ b/libs/hscim/package.yaml @@ -1,5 +1,5 @@ name: hscim -version: 0.3.4 +version: 0.3.5 synopsis: hscim json schema and server implementation description: The README file will answer all the questions you might have homepage: https://github.com/wireapp/wire-server/libs/hscim/README.md diff --git a/libs/hscim/src/Web/Scim/Client.hs b/libs/hscim/src/Web/Scim/Client.hs index d27b83a12f3..4cf0dfdc505 100644 --- a/libs/hscim/src/Web/Scim/Client.hs +++ b/libs/hscim/src/Web/Scim/Client.hs @@ -32,7 +32,7 @@ module Web.Scim.Client getUser, postUser, putUser, - patchUserr, + patchUser, deleteUser, -- * group @@ -143,14 +143,14 @@ putUser :: IO (StoredUser tag) putUser env tok = case users (scimClients env) tok of ((_ :<|> (_ :<|> _)) :<|> (r :<|> (_ :<|> _))) -> r -patchUserr :: +patchUser :: HasScimClient tag => ClientEnv -> Maybe (AuthData tag) -> UserId tag -> PatchOp tag -> IO (StoredUser tag) -patchUserr env tok = case users (scimClients env) tok of ((_ :<|> (_ :<|> _)) :<|> (_ :<|> (r :<|> _))) -> r +patchUser env tok = case users (scimClients env) tok of ((_ :<|> (_ :<|> _)) :<|> (_ :<|> (r :<|> _))) -> r deleteUser :: forall tag. diff --git a/libs/hscim/test/Test/Schema/MetaSchemaSpec.hs b/libs/hscim/test/Test/Schema/MetaSchemaSpec.hs index 4fb0e6414a0..84328580826 100644 --- a/libs/hscim/test/Test/Schema/MetaSchemaSpec.hs +++ b/libs/hscim/test/Test/Schema/MetaSchemaSpec.hs @@ -47,10 +47,11 @@ prop_roundtrip gen = property $ do spec :: Spec spec = do describe "MetaSchema" $ do + -- the extra 'decode' in the golden tests is to make attribute order not count for Eq. it "`Supported ()` golden test" $ do - encode (Supported (ScimBool True) ()) `shouldBe` "{\"supported\":true}" + decode @Value (encode (Supported (ScimBool True) ())) `shouldBe` decode @Value ("{\"supported\":true}") it "`Supported a` golden test" $ do - encode (Supported (ScimBool True) (FilterConfig 3)) `shouldBe` "{\"supported\":true,\"maxResults\":3}" + decode @Value (encode (Supported (ScimBool True) (FilterConfig 3))) `shouldBe` decode @Value "{\"supported\":true,\"maxResults\":3}" it "`Supported ()` roundtrips" $ do require (prop_roundtrip (genSupported (pure ()))) it "`BulkConfig` roundtrips" $ do