1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
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;
|