]> Git — Sourcephile - haskell/symantic.git/blob - symantic-lib/test/HUnit/MonoFunctor.hs
Add colorable and decorable.
[haskell/symantic.git] / symantic-lib / test / HUnit / MonoFunctor.hs
1 {-# OPTIONS_GHC -fno-warn-missing-signatures #-}
2 module HUnit.MonoFunctor where
3
4 import Test.Tasty
5 import Data.Proxy (Proxy(..))
6 import qualified Data.MonoTraversable as MT
7
8 import Language.Symantic.Lib
9 import Testing.Compiling
10
11 type SS =
12 [ Proxy (->)
13 , Proxy []
14 , Proxy Integer
15 , Proxy Bool
16 , Proxy Char
17 , Proxy MT.MonoFunctor
18 , Proxy Maybe
19 ]
20 (==>) = readTe @() @SS
21
22 hunits :: TestTree
23 hunits = testGroup "MonoFunctor"
24 [ "omap not (Just True)" ==> Right (tyMaybe tyBool, Just False, "omap (\\x0 -> not x0) (Just True)")
25 , "omap Char.toUpper ['a', 'b', 'c']" ==> Right (tyList tyChar, "ABC", "omap (\\x0 -> Char.toUpper x0) ('a' : 'b' : 'c' : [])" )
26 ]