3 # Test that untranslated messages that are brought over from the .pot file
4 # get the right number of msgstrs.
7 trap 'rm -fr $tmpfiles' 1 2 3 15
9 tmpfiles
="$tmpfiles mm-test17.po"
10 cat <<\EOF
> mm-test17.po
14 "Content-Type: text/plain; charset=UTF-8\n"
15 "Content-Transfer-Encoding: 8bit\n"
16 "Plural-Forms: nplurals=3; plural=n==1 ? 0 : n==2 ? 1 : 2;\n"
19 msgid
"'Your command, please?', asked the waiter."
23 tmpfiles
="$tmpfiles mm-test17.pot"
24 cat <<\EOF
> mm-test17.pot
25 # SOME DESCRIPTIVE TITLE.
26 # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
27 # This file is distributed under the same license as the PACKAGE package.
28 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
33 "Project-Id-Version: PACKAGE VERSION\n"
34 "Report-Msgid-Bugs-To: \n"
35 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
36 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
37 "Language-Team: LANGUAGE <LL@li.org>\n"
39 "Content-Type: text/plain; charset=CHARSET\n"
40 "Content-Transfer-Encoding: 8bit\n"
43 msgid
"'Your command, please?', asked the waiter."
47 msgid
"a piece of cake"
48 msgid_plural
"%d pieces of cake"
53 msgid
"%s is replaced by %s."
57 tmpfiles
="$tmpfiles mm-test17.new.po"
58 : ${MSGMERGE=msgmerge}
59 ${MSGMERGE} -q mm-test17.po mm-test17.pot
-o mm-test17.new.po
60 test $?
= 0 ||
{ rm -fr $tmpfiles; exit 1; }
62 tmpfiles
="$tmpfiles mm-test17.ok"
63 cat <<\EOF
> mm-test17.ok
67 "Report-Msgid-Bugs-To: \n"
68 "Content-Type: text/plain; charset=UTF-8\n"
69 "Content-Transfer-Encoding: 8bit\n"
70 "Plural-Forms: nplurals=3; plural=n==1 ? 0 : n==2 ? 1 : 2;\n"
73 msgid
"'Your command, please?', asked the waiter."
77 msgid
"a piece of cake"
78 msgid_plural
"%d pieces of cake"
84 msgid
"%s is replaced by %s."
89 ${DIFF} mm-test17.ok mm-test17.new.po