From 46ae60eaca841b554ba20c6a2b7a15b43c12b4df Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Tue, 18 Dec 2018 13:51:16 +0100 Subject: Much ado about nothing --- edit-lens/test/Control/DFST/LensTest.hs | 35 +++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 edit-lens/test/Control/DFST/LensTest.hs (limited to 'edit-lens/test/Control/DFST/LensTest.hs') diff --git a/edit-lens/test/Control/DFST/LensTest.hs b/edit-lens/test/Control/DFST/LensTest.hs new file mode 100644 index 0000000..46a1896 --- /dev/null +++ b/edit-lens/test/Control/DFST/LensTest.hs @@ -0,0 +1,35 @@ +module Control.DFST.LensTest where + +import Prelude hiding (init) + +import Control.DFST +import Control.DFST.Lens +import Control.FST hiding (stInitial, stTransition, stAccept) + +import Data.Set (Set) +import qualified Data.Set as Set + +import Data.Map.Strict (Map) +import qualified Data.Map.Strict as Map + +import Data.Sequence (Seq) +import qualified Data.Sequence as Seq + +import Data.Maybe (maybeToList) + +import Test.Tasty +import Test.Tasty.Hedgehog +import Test.Tasty.HUnit hiding (assert) + +import Hedgehog +import qualified Hedgehog.Gen as G +import qualified Hedgehog.Range as R + +import Numeric.Natural + +import Control.DFSTTest + +hprop_applyDivInit :: Property +hprop_applyDivInit = property $ do + word <- Seq.fromList <$> forAll genWord + init @(StringEdits Natural) `apply` (divInit word :: StringEdits Natural) === Just word -- cgit v1.2.3