Skip to content

Commit

Permalink
TeX: Add format test for input command surrounded curly braces
Browse files Browse the repository at this point in the history
  • Loading branch information
lksj authored and mquinson committed Sep 15, 2024
1 parent 1f740c5 commit 1cebe54
Show file tree
Hide file tree
Showing 6 changed files with 107 additions and 0 deletions.
9 changes: 9 additions & 0 deletions t/fmt-tex.t
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,15 @@ push @tests,
'potfile' => "fmt/tex/input-in-basic.pot",
'pofile' => "fmt/tex/input-in-basic.po",
'trans' => "fmt/tex/input-in-basic.trans"
},
{
'doc' => 'input command surrounded curly braces',
'format' => 'latex',
'input' => "fmt/tex/input-merge-basic-surrounded-curly-braces.tex",
'norm' => "fmt/tex/input-merge-basic-surrounded-curly-braces.norm",
'potfile' => "fmt/tex/input-merge-basic-surrounded-curly-braces.pot",
'pofile' => "fmt/tex/input-merge-basic-surrounded-curly-braces.po",
'trans' => "fmt/tex/input-merge-basic-surrounded-curly-braces.trans"
};

run_all_tests(@tests);
Expand Down
12 changes: 12 additions & 0 deletions t/fmt/tex/input-merge-basic-surrounded-curly-braces.norm
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
% This file was generated with po4a. Translate the source file.
%
\documentclass[12pt]{article}
\begin{document}

same text in basic document

{ same text in subtext.tex }

another text in basic document

\end{document}
32 changes: 32 additions & 0 deletions t/fmt/tex/input-merge-basic-surrounded-curly-braces.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# SOME DESCRIPTIVE TITLE
# Copyright (C) YEAR Free Software Foundation, Inc.
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"POT-Creation-Date: 2024-09-15 12:25+0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"

#. type: document
#: input-merge-basic-surrounded-curly-braces.tex:5
msgid "same text in basic document"
msgstr "SAME TEXT IN BASIC DOCUMENT"

#. type: document
#: input-merge-basic-surrounded-curly-braces.tex:7
msgid "{ same text in subtext.tex }"
msgstr "{ SAME TEXT IN SUBTEXT.TEX }"

#. type: document
#: input-merge-basic-surrounded-curly-braces.tex:9
msgid "another text in basic document"
msgstr "ANOTHER TEXT IN BASIC DOCUMENT"
32 changes: 32 additions & 0 deletions t/fmt/tex/input-merge-basic-surrounded-curly-braces.pot
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# SOME DESCRIPTIVE TITLE
# Copyright (C) YEAR Free Software Foundation, Inc.
# This file is distributed under the same license as the PACKAGE package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"POT-Creation-Date: 2024-09-15 12:26+0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <[email protected]>\n"
"Language: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"

#. type: document
#: input-merge-basic-surrounded-curly-braces.tex:5
msgid "same text in basic document"
msgstr ""

#. type: document
#: input-merge-basic-surrounded-curly-braces.tex:7
msgid "{ same text in subtext.tex }"
msgstr ""

#. type: document
#: input-merge-basic-surrounded-curly-braces.tex:9
msgid "another text in basic document"
msgstr ""
10 changes: 10 additions & 0 deletions t/fmt/tex/input-merge-basic-surrounded-curly-braces.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
\documentclass[12pt]{article}
\begin{document}

same text in basic document

{\input{subtext.tex}}

another text in basic document

\end{document}
12 changes: 12 additions & 0 deletions t/fmt/tex/input-merge-basic-surrounded-curly-braces.trans
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
% This file was generated with po4a. Translate the source file.
%
\documentclass[12pt]{article}
\begin{document}

SAME TEXT IN BASIC DOCUMENT

{ SAME TEXT IN SUBTEXT.TEX }

ANOTHER TEXT IN BASIC DOCUMENT

\end{document}

0 comments on commit 1cebe54

Please sign in to comment.