mirror of
https://github.com/xmonad/xmonad-contrib.git
synced 2025-05-19 03:20:21 -07:00
Tests: Add tests for OrgMode regressions
Add regression tests to make sure we keep the behaviour fixed by 97aeaf11c10a0f38b4cd1df4726a10bb9188f4ca. Related: https://github.com/xmonad/xmonad-contrib/issues/584
This commit is contained in:
parent
b42303aa6f
commit
e4b8b1f6f2
@ -22,6 +22,14 @@ spec = do
|
||||
prop "prop_encodeLinearity" prop_encodeLinearity
|
||||
prop "prop_decodeLinearity" prop_decodeLinearity
|
||||
|
||||
-- Checking for regressions
|
||||
context "+d +d f" $ do
|
||||
it "encode" $ prop_encodeLinearity (OrgMsg "+d +d f")
|
||||
it "decode" $ prop_decodeLinearity (Deadline "+d" (Time {date = Next Friday, tod = Nothing}))
|
||||
context "+d f 1 +d f" $ do
|
||||
it "encode" $ prop_encodeLinearity (OrgMsg "+d f 1 +d f")
|
||||
it "decode" $ prop_decodeLinearity (Deadline "+d f 1" (Time {date = Next Friday, tod = Nothing}))
|
||||
|
||||
-- | Printing omits no information from output.
|
||||
prop_encodeLinearity :: OrgMsg -> Property
|
||||
prop_encodeLinearity (OrgMsg s) = Just s === (ppNote <$> pInput s)
|
||||
|
Loading…
x
Reference in New Issue
Block a user