From 4e34d366df31937cdc69b6b366355f10a84c16b2 Mon Sep 17 00:00:00 2001 From: despresc Date: Sat, 4 Apr 2020 16:35:42 -0400 Subject: Adapt to the newest Table type, fix some previous adaptation issues - Writers.Native is now adapted to the new Table type. - Inline captions should now be conditionally wrapped in a Plain, not a Para block. - The toLegacyTable function now lives in Writers.Shared. --- test/Tests/Writers/ConTeXt.hs | 2 +- test/Tests/Writers/Muse.hs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'test/Tests/Writers') diff --git a/test/Tests/Writers/ConTeXt.hs b/test/Tests/Writers/ConTeXt.hs index ea717b48e..cc90b95a9 100644 --- a/test/Tests/Writers/ConTeXt.hs +++ b/test/Tests/Writers/ConTeXt.hs @@ -99,7 +99,7 @@ tests = [ testGroup "inline code" , testGroup "natural tables" [ test contextNtb "table with header and caption" $ let capt = text "Table 1" - aligns = [(AlignRight, Nothing), (AlignLeft, Nothing), (AlignCenter, Nothing), (AlignDefault, Nothing)] + aligns = [(AlignRight, ColWidthDefault), (AlignLeft, ColWidthDefault), (AlignCenter, ColWidthDefault), (AlignDefault, ColWidthDefault)] headers = [plain $ text "Right", plain $ text "Left", plain $ text "Center", diff --git a/test/Tests/Writers/Muse.hs b/test/Tests/Writers/Muse.hs index ba5fdf94f..42748ad85 100644 --- a/test/Tests/Writers/Muse.hs +++ b/test/Tests/Writers/Muse.hs @@ -372,7 +372,7 @@ tests = [ testGroup "block elements" [ "table without header" =: let rows = [[para "Para 1.1", para "Para 1.2"] ,[para "Para 2.1", para "Para 2.2"]] - in table mempty [(AlignDefault,Nothing),(AlignDefault,Nothing)] + in table mempty [(AlignDefault,ColWidthDefault),(AlignDefault,ColWidthDefault)] [mempty, mempty] rows =?> unlines [ " Para 1.1 | Para 1.2" @@ -393,7 +393,7 @@ tests = [ testGroup "block elements" headers = [plain "header 1", plain "header 2"] rows = [[para "Para 1.1", para "Para 1.2"] ,[para "Para 2.1", para "Para 2.2"]] - in table capt [(AlignDefault,Nothing),(AlignDefault,Nothing)] + in table capt [(AlignDefault,ColWidthDefault),(AlignDefault,ColWidthDefault)] headers rows =?> unlines [ " header 1 || header 2" , " Para 1.1 | Para 1.2" -- cgit v1.2.3