From ec48a785a4fd5fc52ae667e442079b70489b7eba Mon Sep 17 00:00:00 2001 From: Mathias Kende Date: Sun, 24 Mar 2024 23:17:24 +0100 Subject: [PATCH] Add a test for the allow_task_list_markers options. --- t/400-opt-allow_task_list_markers.t | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 t/400-opt-allow_task_list_markers.t diff --git a/t/400-opt-allow_task_list_markers.t b/t/400-opt-allow_task_list_markers.t new file mode 100644 index 0000000..d61ce42 --- /dev/null +++ b/t/400-opt-allow_task_list_markers.t @@ -0,0 +1,14 @@ +use strict; +use warnings; +use utf8; + +use Markdown::Perl 'convert'; +use Test2::V0; + +my $cb = ''; + +is(convert("- [ ] foo\n\n [ ] bar", allow_task_list_markers => 'never'), "\n", 'never'); +is(convert("- [ ] foo\n\n [ ] bar", allow_task_list_markers => 'list'), "\n", 'list'); +is(convert("- [ ] foo\n\n [ ] bar", allow_task_list_markers => 'always'), "\n", 'always'); + +done_testing;