2 . "${srcdir=.}/init.sh"; path_prepend_ . ../src
4 # Test that untranslated messages that are brought over from the .pot file
5 # get the right number of msgstrs.
7 cat <<\EOF > mm-test17.po
11 "Content-Type: text/plain; charset=UTF-8\n"
12 "Content-Transfer-Encoding: 8bit\n"
13 "Plural-Forms: nplurals=3; plural=n==1 ? 0 : n==2 ? 1 : 2;\n"
16 msgid "'Your command, please?', asked the waiter."
20 cat <<\EOF > mm-test17.pot
21 # SOME DESCRIPTIVE TITLE.
22 # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
23 # This file is distributed under the same license as the PACKAGE package.
24 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
29 "Project-Id-Version: PACKAGE VERSION\n"
30 "Report-Msgid-Bugs-To: \n"
31 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
32 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
33 "Language-Team: LANGUAGE <LL@li.org>\n"
35 "Content-Type: text/plain; charset=CHARSET\n"
36 "Content-Transfer-Encoding: 8bit\n"
39 msgid "'Your command, please?', asked the waiter."
43 msgid "a piece of cake"
44 msgid_plural "%d pieces of cake"
49 msgid "%s is replaced by %s."
53 : ${MSGMERGE=msgmerge}
54 ${MSGMERGE} -q -o mm-test17.tmp.po mm-test17.po mm-test17.pot || exit 1
55 LC_ALL=C tr -d '\r' < mm-test17.tmp.po > mm-test17.new.po || exit 1
57 cat <<\EOF > mm-test17.ok
61 "Report-Msgid-Bugs-To: \n"
62 "Content-Type: text/plain; charset=UTF-8\n"
63 "Content-Transfer-Encoding: 8bit\n"
64 "Plural-Forms: nplurals=3; plural=n==1 ? 0 : n==2 ? 1 : 2;\n"
67 msgid "'Your command, please?', asked the waiter."
71 msgid "a piece of cake"
72 msgid_plural "%d pieces of cake"
78 msgid "%s is replaced by %s."
83 ${DIFF} mm-test17.ok mm-test17.new.po