3 # Copyright (C) 2021 Free Software Foundation, Inc.
5 # This file is part of groff.
7 # groff is free software; you can redistribute it and/or modify it under
8 # the terms of the GNU General Public License as published by the Free
9 # Software Foundation, either version 3 of the License, or
10 # (at your option) any later version.
12 # groff is distributed in the hope that it will be useful, but WITHOUT
13 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
17 # You should have received a copy of the GNU General Public License
18 # along with this program. If not, see <http://www.gnu.org/licenses/>.
23 grog="${abs_top_builddir:-.}/grog"
24 src="${abs_top_srcdir:-..}"
26 doc=src/preproc/eqn/neqn.1
27 echo "testing simple man(7) page $doc" >&2
29 grep -Fqx 'groff -man '"$doc"
31 doc=src/preproc/tbl/tbl.1
32 echo "testing tbl(1)-using man(7) page $doc" >&2
34 grep -Fqx 'groff -t -man '"$doc"
37 echo "testing eqn(1)-using man(7) page $doc" >&2
39 grep -Fqx 'groff -e -man '"$doc"
41 # BUG: grog doesn't yet handle .if, .ie, .while.
42 #doc=src/preproc/soelim/soelim.1
43 #echo "testing pic(1)-using man(7) page $doc" >&2
45 # grep -Fqx 'groff -p -man '"$doc"
48 echo "testing tbl(1)-using mdoc(7) page $doc" >&2
50 grep -Fqx 'groff -t -mdoc '"$doc"
52 doc=$src/doc/meintro.me.in
53 echo "testing me(7) document $doc" >&2
55 grep -Fqx 'groff -me '"$doc"
57 doc=$src/doc/meintro_fr.me.in
58 echo "testing tbl(1)-using me(7) document $doc" >&2
60 grep -Fqx 'groff -t -me '"$doc"
62 doc=$src/doc/meref.me.in
63 echo "testing me(7) document $doc" >&2
65 grep -Fqx 'groff -me '"$doc"
67 doc=$src/doc/grnexmpl.me
68 echo "testing grn(1)- and eqn(1)-using me(7) document $doc" >&2
70 grep -Fqx 'groff -e -g -me '"$doc"
72 doc=$src/contrib/mm/examples/letter.mm
73 echo "testing mm(7) document $doc" >&2
75 grep -Fqx 'groff -mm '"$doc"
77 doc=$src/contrib/mom/examples/copyright-chapter.mom
78 echo "testing mom(7) document $doc" >&2
80 grep -Fqx 'groff -mom '"$doc"
82 doc=$src/contrib/mom/examples/copyright-default.mom
83 echo "testing mom(7) document $doc" >&2
85 grep -Fqx 'groff -mom '"$doc"
87 doc=$src/contrib/mom/examples/letter.mom
88 echo "testing mom(7) document $doc" >&2
90 grep -Fqx 'groff -mom '"$doc"
92 doc=$src/contrib/mom/examples/mom-pdf.mom
93 echo "testing mom(7) document $doc" >&2
95 grep -Fqx 'groff -mom '"$doc"
97 doc=$src/contrib/mom/examples/mon_premier_doc.mom
98 echo "testing mom(7) document $doc" >&2
100 grep -Fqx 'groff -mom '"$doc"
102 doc=$src/contrib/mom/examples/sample_docs.mom
103 echo "testing mom(7) document $doc" >&2
105 grep -Fqx 'groff -mom '"$doc"
107 doc=$src/contrib/mom/examples/slide-demo.mom
108 echo "testing mom(7) document $doc" >&2
110 grep -Fqx 'groff -e -p -t -mom '"$doc"
112 doc=$src/contrib/mom/examples/typesetting.mom
113 echo "testing mom(7) document $doc" >&2
115 grep -Fqx 'groff -mom '"$doc"
117 doc=$src/contrib/pdfmark/cover.ms
118 echo "testing ms(7) document $doc" >&2
120 grep -Fqx 'groff -ms '"$doc"
122 doc=$src/contrib/pdfmark/pdfmark.ms
123 echo "testing ms(7) document $doc" >&2
125 grep -Fqx 'groff -ms '"$doc"
128 echo "testing eqn(1)- and tbl(1)-using ms(7) document $doc" >&2
130 grep -Fqx 'groff -e -t -ms '"$doc"
133 echo "testing tbl(1)-, eqn(1)-, and pic(1)-using ms(7) document $doc" \
136 grep -Fqx 'groff -e -p -t -ms '"$doc"
138 doc=$src/doc/webpage.ms
139 echo "testing ms(7) document $doc" >&2
140 # BUG: Should detect -mwww (and -mpspic?) too.
142 grep -Fqx 'groff -ms '"$doc"
144 # Test manual specification of auxiliary macro packages.
145 echo "testing ms(7) document $doc with '-m www' option" >&2
146 "$grog" "$doc" -m www | \
147 grep -Fqx 'groff -ms -mwww '"$doc"
149 echo "testing ms(7) document $doc with '-mwww' option" >&2
150 "$grog" "$doc" -mwww | \
151 grep -Fqx 'groff -ms -mwww '"$doc"
153 # vim:set ai et sw=4 ts=4 tw=72: