From e3c36ed6ce5f9ea3e06c491d5a1ac892bfcd6089 Mon Sep 17 00:00:00 2001 From: Albert Krewinkel Date: Sat, 18 Oct 2014 21:59:44 +0200 Subject: Org reader: Drop COMMENT document trees Document trees under a header starting with the word `COMMENT` are comment trees and should not be exported. Those trees are dropped silently. This closes #1678. --- tests/Tests/Readers/Org.hs | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'tests') diff --git a/tests/Tests/Readers/Org.hs b/tests/Tests/Readers/Org.hs index 92ec8155b..b37825ad5 100644 --- a/tests/Tests/Readers/Org.hs +++ b/tests/Tests/Readers/Org.hs @@ -450,6 +450,18 @@ tests = , header 2 ("walk" <> space <> "dog") ] + , "Comment Trees" =: + unlines [ "* COMMENT A comment tree" + , " Not much going on here" + , "** This will be dropped" + , "* Comment tree above" + ] =?> + header 1 "Comment tree above" + + , "Nothing but a COMMENT header" =: + "* COMMENT Test" =?> + (mempty::Blocks) + , "Paragraph starting with an asterisk" =: "*five" =?> para "*five" -- cgit v1.2.3