From 79e4b9f695d1a25c960eb2f6a86aabe169f78a8e Mon Sep 17 00:00:00 2001 From: Lars Wirzenius Date: Sun, 31 Jul 2022 11:14:16 +0300 Subject: feat: check for definition lists, and fail if found Sponsored-by: author --- riki.md | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) (limited to 'riki.md') diff --git a/riki.md b/riki.md index 6fc0d53..e208baa 100644 --- a/riki.md +++ b/riki.md @@ -334,6 +334,52 @@ then AST of site/page.mdwn matches that of output/page.html * [x] done ~~~ +## Definition list + +_Requirement: Markup indicating use of a definition list should be +flagged as an error._ + +Justification: Neither the CommonMark specification, nor GitHub +Flavored Markdown, supports definition lists, even though some +Markdown variants do. The Markdown parser Riki uses doesn't support +it. + +~~~scenario +given an installed riki + +given file site/page.mdwn from dl-1 +when I try to run riki build --plain-body site output +then command fails +then stderr contains "definition list" + +given file site/page.mdwn from dl-2 +when I try to run riki build --plain-body site output +then command fails +then stderr contains "definition list" + +given file site/page.mdwn from dl-3 +when I run riki build --plain-body site output +then file output/page.html contains ": bar" +~~~ + +~~~{#dl-1 .file} +foo +: bar +~~~ + +~~~{#dl-2 .file} +foo + +: bar +~~~ + +~~~{#dl-3 .file} +foo + +: bar +~~~ + + ## Input files other than Markdown _Requirement: Input files that aren't Markdown files must be copied -- cgit v1.2.1