mirror of
https://github.com/github/semantic.git
synced 2024-12-27 00:44:57 +03:00
21 lines
540 B
Haskell
21 lines
540 B
Haskell
|
module Data.Semigroup.App.Spec where
|
||
|
|
||
|
import SpecHelpers
|
||
|
import Data.Semigroup.App
|
||
|
|
||
|
spec :: Spec
|
||
|
spec = do
|
||
|
describe "App" $
|
||
|
prop "should be associative" $
|
||
|
\a b c -> a <> (b <> c) == (a <> b) <> (c :: App Maybe Integer)
|
||
|
|
||
|
describe "AppMerge" $ do
|
||
|
prop "should be associative" $
|
||
|
\ a b c -> a <> (b <> c) == (a <> b) <> (c :: AppMerge Maybe String)
|
||
|
|
||
|
prop "identity/left" $
|
||
|
\ a -> mempty <> a == (a :: AppMerge Maybe String)
|
||
|
|
||
|
prop "identity/right" $
|
||
|
\ a -> a <> mempty == (a :: AppMerge Maybe String)
|