diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-17 11:26:17 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-17 11:26:17 +0000 |
commit | 5df6c2aefebe3d2abcc939a88e294876d59f03ca (patch) | |
tree | 63fb332a0f21ddb91cb789c80cf64e134d373463 /t/fmt-asciidoc.t | |
parent | Initial commit. (diff) | |
download | po4a-5df6c2aefebe3d2abcc939a88e294876d59f03ca.tar.xz po4a-5df6c2aefebe3d2abcc939a88e294876d59f03ca.zip |
Adding upstream version 0.72.upstream/0.72
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 't/fmt-asciidoc.t')
-rw-r--r-- | t/fmt-asciidoc.t | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/t/fmt-asciidoc.t b/t/fmt-asciidoc.t new file mode 100644 index 0000000..74aac07 --- /dev/null +++ b/t/fmt-asciidoc.t @@ -0,0 +1,68 @@ +#! /usr/bin/perl +# Text module tester. + +######################### + +use strict; +use warnings; + +use lib q(t); +use Testhelper; + +my @tests; + +foreach my $t ( + qw(Titles BlockTitles BlockId Paragraphs DelimitedBlocks Lists Footnotes Callouts Comments Tables TablesImageText Attributes StyleMacro MacroIncludesHugo IndexEntries) + ) +{ + push @tests, { 'format' => 'asciidoc', 'input' => "fmt/asciidoc/$t.adoc" }; +} + +push @tests, + { + 'format' => 'asciidoc', + 'options' => '-o compat=asciidoctor', + 'input' => 'fmt/asciidoc/StrictDelimitedBlocks.adoc', + 'doc' => 'asciidoctor block fence parsing', + }, + { + 'format' => 'asciidoc', + 'options' => '-o tablecells=1', + 'input' => 'fmt/asciidoc/TablesCells.adoc', + 'doc' => 'test table cells segmentation', + }, + { + 'format' => 'asciidoc', + 'options' => '-o noimagetargets=1', + 'input' => "fmt/asciidoc/NoImageTarget.adoc", + 'doc' => "test ignoring image targets", + }, + { + 'format' => 'asciidoc', + 'options' => '-o nolinting=1', + 'input' => "fmt/asciidoc/LineBreak.adoc", + }, + { + 'format' => 'asciidoc', + 'options' => '-o cleanspaces=1', + 'input' => "fmt/asciidoc/CleanSpaces.adoc", + }, + { + 'format' => 'asciidoc', + 'input' => "fmt/asciidoc/YamlFrontMatter.adoc", + }, + { + 'doc' => "That the yfm_keys and yfm_skip_array options actually work", + 'format' => 'asciidoc', + 'options' => "-o yfm_skip_array -o yfm_keys='title , subtitle,paragraph'", + 'input' => "fmt/asciidoc/YamlFrontMatter_Option.adoc", + }, + { + 'doc' => "That the yfm_keys and yfm_paths options actually work", + 'format' => 'asciidoc', + 'options' => "-o yfm_skip_array -o yfm_keys='subtitle , paragraph' -o yfm_paths='people title'", + 'input' => "fmt/asciidoc/YamlFrontMatter_KeysPaths.adoc", + }; + +run_all_tests(@tests); +0; |