diff --git a/test/Data/Functor/Both/Spec.hs b/test/Data/Functor/Both/Spec.hs index e1ce51f28..25d998543 100644 --- a/test/Data/Functor/Both/Spec.hs +++ b/test/Data/Functor/Both/Spec.hs @@ -1 +1,12 @@ -module Data.Functor.Both.Spec where +module Data.Functor.Both.Spec (spec) where + +import Data.Coalescent +import Data.Functor.Both +import Line +import Test.Hspec + +spec :: Spec +spec = do + describe "Coalescent" $ do + it "should coalesce when both sides coalesce" $ + (both (Line [True]) (Line [True]) `coalesce` both (Line [True]) (Line [True]) :: [Both (Line Bool)]) `shouldBe` [both (Line [True, True]) (Line [True, True])] diff --git a/test/Spec.hs b/test/Spec.hs index ba2c9bd74..0f6609a7a 100644 --- a/test/Spec.hs +++ b/test/Spec.hs @@ -3,6 +3,7 @@ module Main where import qualified AlignmentSpec import qualified CorpusSpec import qualified Data.Adjoined.Spec +import qualified Data.Functor.Both.Spec import qualified InterpreterSpec import qualified OrderedMapSpec import qualified PatchOutputSpec @@ -14,6 +15,7 @@ main = hspec $ parallel $ do describe "Alignment" AlignmentSpec.spec describe "Corpus" CorpusSpec.spec describe "Data.Adjoined" Data.Adjoined.Spec.spec + describe "Data.Functor.Both" Data.Functor.Both.Spec.spec describe "Interpreter" InterpreterSpec.spec describe "OrderedMap" OrderedMapSpec.spec describe "PatchOutput" PatchOutputSpec.spec