packages feed

monoidmap-aeson 0.0.0.6 → 0.0.0.7

raw patch · 9 files changed

+35/−77 lines, 9 filesdep +hspec-quickcheck-classesdep ~QuickCheckdep ~basedep ~containersPVP ok

version bump matches the API change (PVP)

Dependencies added: hspec-quickcheck-classes

Dependency ranges changed: QuickCheck, base, containers

API changes (from Hackage documentation)

Files

CHANGELOG.md view
@@ -1,3 +1,8 @@+# 0.0.0.7++- Added support for GHC version `9.14`.+- Revised version bounds for dependencies.+ # 0.0.0.6  - Revised version bounds for dependencies.
LICENSE view
@@ -186,7 +186,7 @@       same "printed page" as the copyright notice for easier       identification within third-party archives. -   Copyright © 2022–2025 Jonathan Knowles+   Copyright © 2022–2026 Jonathan Knowles     Licensed under the Apache License, Version 2.0 (the "License");    you may not use this file except in compliance with the License.
README.md view
@@ -1,6 +1,13 @@ # `monoidmap-aeson`
-<a href="https://jonathanknowles.github.io/monoidmap-aeson/"><img src="https://img.shields.io/badge/API-Documentation-227755" /></a>
 
+[![Latest Release](
+  https://img.shields.io/hackage/v/monoidmap-aeson?label=Latest%20Release&color=227755
+)](https://hackage.haskell.org/package/monoidmap-aeson)
+[![Development Branch](
+  https://img.shields.io/badge/Development%20Branch-API%20Documentation-225577
+)](https://jonathanknowles.github.io/monoidmap-aeson/)
+
 ## Overview
 
 This package provides JSON serialisation support for the [`monoidmap`](https://hackage.haskell.org/package/monoidmap) package with [`aeson`](https://hackage.haskell.org/package/aeson).
+
components/monoidmap-aeson-test/Data/MonoidMap/JSONSpec.hs view
@@ -2,7 +2,7 @@ {-# OPTIONS_GHC -fno-warn-orphans #-}  -- |--- Copyright: © 2022–2025 Jonathan Knowles+-- Copyright: © 2022–2026 Jonathan Knowles -- License: Apache-2.0 -- module Data.MonoidMap.JSONSpec@@ -44,7 +44,7 @@ import Test.QuickCheck.Classes     ( jsonLaws     )-import Test.QuickCheck.Classes.Hspec+import Test.Hspec.QuickCheck.Classes     ( testLaws     ) @@ -61,7 +61,7 @@  specForTypes :: forall k v. (Test k v) => Proxy k -> Proxy v -> Spec specForTypes = makeSpec $ do-    testLaws @(MonoidMap k v) jsonLaws+    testLaws @(MonoidMap k v) [jsonLaws]     goldenSpecs goldenSettings (Proxy @(MonoidMap k v))  goldenSettings :: Golden.Settings
components/monoidmap-aeson-test/Test/Common.hs view
@@ -1,3 +1,4 @@+{-# LANGUAGE CPP #-} {-# LANGUAGE ExistentialQuantification #-} {-# OPTIONS_GHC -fno-warn-orphans #-} {- HLINT ignore "Redundant bracket" -}@@ -5,7 +6,7 @@ {- HLINT ignore "Use null" -}  -- |--- Copyright: © 2022–2025 Jonathan Knowles+-- Copyright: © 2022–2026 Jonathan Knowles -- License: Apache-2.0 -- module Test.Common@@ -99,15 +100,21 @@   where     function = functionMap MonoidMap.toMap MonoidMap.fromMap +#if !MIN_VERSION_QuickCheck(2,17,0) instance Arbitrary Natural where     arbitrary = arbitrarySizedIntegral     shrink = shrinkIntegral+#endif +#if !MIN_VERSION_QuickCheck(2,18,0) instance CoArbitrary Natural where     coarbitrary = coarbitraryIntegral+#endif +#if !MIN_VERSION_QuickCheck(2,18,0) instance Function Natural where     function = functionIntegral+#endif  instance Arbitrary Text where     arbitrary = Text.pack <$> listOf genChar
components/monoidmap-aeson-test/Test/Key.hs view
@@ -3,7 +3,7 @@ {-# LANGUAGE DeriveGeneric #-}  -- |--- Copyright: © 2022–2025 Jonathan Knowles+-- Copyright: © 2022–2026 Jonathan Knowles -- License: Apache-2.0 -- -- Quasi-unique keys.
− components/monoidmap-aeson-test/Test/QuickCheck/Classes/Hspec.hs
@@ -1,63 +0,0 @@-{-# LANGUAGE PolyKinds #-}---- |--- Copyright: © 2022–2025 Jonathan Knowles--- License: Apache-2.0------ Provides testing functions to check that type class instances obey laws.----module Test.QuickCheck.Classes.Hspec-    ( testLaws-    , testLawsMany-    ) where--import Prelude--import Control.Monad-    ( forM_ )-import Data.Proxy-    ( Proxy (..) )-import Data.Typeable-    ( Typeable, typeRep )-import Test.Hspec-    ( Spec, describe, it, parallel )-import Test.QuickCheck.Classes-    ( Laws (..) )---- | Constructs a test to check that the given type class instance obeys the---   given set of laws.------ Example usage:------ >>> testLaws @Natural ordLaws--- >>> testLaws @(Map Int) functorLaws----testLaws-    :: forall a. Typeable a-    => (Proxy a -> Laws)-    -> Spec-testLaws getLaws =-    parallel $ describe description $-        forM_ (lawsProperties laws) $ uncurry it-  where-    description = mconcat-        [ "Testing "-        , lawsTypeclass laws-        , " laws for type "-        , show (typeRep $ Proxy @a)-        ]-    laws = getLaws $ Proxy @a---- | Calls `testLaws` with multiple sets of laws.------ Example usage:------ >>> testLawsMany @Natural [eqLaws, ordLaws]--- >>> testLawsMany @(Map Int) [foldableLaws, functorLaws]----testLawsMany-    :: forall a. Typeable a-    => [Proxy a -> Laws]-    -> Spec-testLawsMany getLawsMany =-    testLaws @a `mapM_` getLawsMany
components/monoidmap-aeson/Data/MonoidMap/JSON.hs view
@@ -1,7 +1,7 @@ {-# OPTIONS_GHC -Wno-orphans #-}  -- |--- Copyright: © 2022–2025 Jonathan Knowles+-- Copyright: © 2022–2026 Jonathan Knowles -- License: Apache-2.0 -- module Data.MonoidMap.JSON
monoidmap-aeson.cabal view
@@ -1,12 +1,12 @@ cabal-version:  3.0 name:           monoidmap-aeson-version:        0.0.0.6+version:        0.0.0.7 bug-reports:    https://github.com/jonathanknowles/monoidmap-aeson/issues license:        Apache-2.0 license-file:   LICENSE author:         Jonathan Knowles maintainer:     mail@jonathanknowles.net-copyright:      2022–2025 Jonathan Knowles+copyright:      2022–2026 Jonathan Knowles category:       Data Structures synopsis:       JSON support for monoidmap. description:    JSON support for the monoidmap package, compatible with aeson.@@ -21,19 +21,21 @@ common dependency-aeson     build-depends:aeson                         >= 2.2.3.0    && < 2.3 common dependency-base-    build-depends:base                          >= 4.14.3.0   && < 4.22+    build-depends:base                          >= 4.14.3.0   && < 4.23 common dependency-containers-    build-depends:containers                    >= 0.6.5.1    && < 0.8+    build-depends:containers                    >= 0.6.5.1    && < 0.9 common dependency-hspec     build-depends:hspec                         >= 2.10.9     && < 2.12 common dependency-hspec-golden-aeson     build-depends:hspec-golden-aeson            >= 0.9.0.0    && < 0.10+common dependency-hspec-quickcheck-classes+    build-depends:hspec-quickcheck-classes      >= 0.0.0.0    && < 0.1 common dependency-monoid-subclasses     build-depends:monoid-subclasses             >= 1.2.3      && < 1.3 common dependency-monoidmap     build-depends:monoidmap                     >= 0.0.4.4    && < 0.1 common dependency-QuickCheck-    build-depends:QuickCheck                    >= 2.14.2     && < 2.17+    build-depends:QuickCheck                    >= 2.14.2     && < 2.19 common dependency-quickcheck-classes     build-depends:quickcheck-classes            >= 0.6.5.0    && < 0.7 common dependency-quickcheck-quid@@ -87,6 +89,7 @@       , dependency-containers       , dependency-hspec       , dependency-hspec-golden-aeson+      , dependency-hspec-quickcheck-classes       , dependency-monoid-subclasses       , dependency-monoidmap       , dependency-QuickCheck@@ -106,7 +109,6 @@         SpecHook         Data.MonoidMap.JSONSpec         Test.Common-        Test.QuickCheck.Classes.Hspec         Test.Key     type:         exitcode-stdio-1.0