quickcheck-dynamic 1.0.0 → 1.1.0
raw patch · 4 files changed
+29/−7 lines, 4 filesPVP ok
version bump matches the API change (PVP)
API changes (from Hackage documentation)
- Test.QuickCheck.DynamicLogic.Quantify: type family Quantifies q;
- Test.QuickCheck.StateModel: data family Action state a;
+ Test.QuickCheck.DynamicLogic.Quantify: type Quantifies q;
+ Test.QuickCheck.StateModel: data Action state a;
- Test.QuickCheck.StateModel: monitoring :: StateModel state => (state, state) -> Action state a -> LookUp -> a -> Property -> Property
+ Test.QuickCheck.StateModel: monitoring :: (StateModel state, Show a) => (state, state) -> Action state a -> LookUp -> a -> Property -> Property
Files
- CHANGELOG.md +21/−0
- README.md +3/−3
- quickcheck-dynamic.cabal +3/−2
- src/Test/QuickCheck/StateModel.hs +2/−2
+ CHANGELOG.md view
@@ -0,0 +1,21 @@+# Changelog++All notable changes to this project will be documented in this file.++The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/).++As a minor extension, we also keep a semantic version for the `UNRELEASED`+changes.++## UNRELEASED+++## 1.1.0 - 2022-08-27++* Fix broken links in Hackage-generated documentation and link to other Quviq papers+* Add `Show a` constraint on `monitoring`++## 1.0.0++* Initial publication of quickcheck-dynamic library on Hackage+* Provide base `StateModel` and `DynamicLogic` tools to write quickcheck-based models, express properties, and test them
README.md view
@@ -14,10 +14,10 @@ ## Usage * Documentation is currenly mostly provided inline as Haddock- comments. Checkout [StateModel](src/Test/QuickCheck/StateModel.hs)- and [DynamicLogic](src/Test/QuickCheck/DynamicLogic.hs) modules for+ comments. Checkout [StateModel](https://hackage.haskell.org/package/quickcheck-dynamic/docs/src/Test.QuickCheck.StateModel.html)+ and [DynamicLogic](https://hackage.haskell.org/package/quickcheck-dynamic/docs/Test-QuickCheck-DynamicLogic.html) modules for some usage instructions.-* For a concrete standalone example, have a look at [Registry](../quickcheck-io-sim-compat/test/Spec/DynamicLogic/Registry.hs), a multithreaded Thread registry.+* For a concrete standalone example, have a look at `Registry` and `RegistryModel` modules from the companion [quickcheck-io-sim-compat](https://github.com/input-output-hk/quickcheck-dynamic/tree/main/quickcheck-io-sim-compat) package (not currently available on hackage), a multithreaded Thread registry inspired by the Erlang version of QuickCheck described in [this article](https://mengwangoxf.github.io/Papers/Erlang18.pdf) * For more documentation on how to quickcheck-dynamic is used to test Plutus DApps, check this [tutorial](https://plutus-apps.readthedocs.io/en/latest/plutus/tutorials/contract-models.html).
quickcheck-dynamic.cabal view
@@ -1,6 +1,6 @@ cabal-version: 2.2 name: quickcheck-dynamic-version: 1.0.0+version: 1.1.0 license: Apache-2.0 license-files: LICENSE@@ -22,7 +22,8 @@ build-type: Simple extra-doc-files: README.md-+extra-source-files: CHANGELOG.md+ source-repository head type: git location: https://github.com/input-output-hk/quickcheck-dynamic
src/Test/QuickCheck/StateModel.hs view
@@ -7,11 +7,11 @@ {-# LANGUAGE PatternSynonyms #-} {-# LANGUAGE QuantifiedConstraints #-} {-# LANGUAGE RankNTypes #-}+{-# LANGUAGE RecordWildCards #-} {-# LANGUAGE StandaloneDeriving #-} {-# LANGUAGE TypeApplications #-} {-# LANGUAGE TypeFamilies #-} {-# LANGUAGE UndecidableInstances #-}-{-# LANGUAGE RecordWildCards #-} -- | Simple (stateful) Model-Based Testing library for use with Haskell QuickCheck. --@@ -133,7 +133,7 @@ -- This function is given the full transition that's been executed, including the start and ending -- `state`, the `Action`, the current environment to `Lookup` and the value produced by `perform` -- while executing this step.- monitoring :: (state, state) -> Action state a -> LookUp -> a -> Property -> Property+ monitoring :: Show a => (state, state) -> Action state a -> LookUp -> a -> Property -> Property monitoring _ _ _ _ = id -- | Perform an `Action` in some `state` in the `Monad` `m`. This