Imported Upstream version 0.18.1.1
[platform/upstream/gettext.git] / gettext-tools / tests / msgmerge-update-4
1 #! /bin/sh
2
3 # Test --update with --sort-output: POT-Creation-Date changed. This change
4 # must not be reflected in the resulting PO file; this is needed for projects
5 # which don't put the .pot file under CVS.
6
7 tmpfiles=""
8 trap 'rm -fr $tmpfiles' 1 2 3 15
9
10 tmpfiles="$tmpfiles mm-u-4.po"
11 cat <<\EOF > mm-u-4.po
12 # SOME DESCRIPTIVE TITLE.
13 # Copyright (C) YEAR Free Software Foundation, Inc.
14 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
15 #
16 msgid ""
17 msgstr ""
18 "Project-Id-Version: cog_training 1.0\n"
19 "POT-Creation-Date: 2001-04-29 22:40+0200\n"
20 "PO-Revision-Date: 2001-04-29 21:19+02:00\n"
21 "Last-Translator: Felix N. <xyz@zyx.uucp>\n"
22 "Language-Team: German <de@li.org>\n"
23 "Language: de\n"
24 "MIME-Version: 1.0\n"
25 "Content-Type: text/plain; charset=ISO-8859-1\n"
26 "Content-Transfer-Encoding: 8bit\n"
27
28 #: cogarithmetic.cc:12 cogidmarkup.cc:288 cogroman.cc:14
29 msgid "white"
30 msgstr "weiß"
31
32 #~ msgid "green"
33 #~ msgstr "grün"
34 EOF
35
36 tmpfiles="$tmpfiles mm-u-4.pot"
37 cat <<EOF > mm-u-4.pot
38 # SOME DESCRIPTIVE TITLE.
39 # Copyright (C) YEAR Free Software Foundation, Inc.
40 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
41 #
42 msgid ""
43 msgstr ""
44 "Project-Id-Version: PACKAGE VERSION\n"
45 "POT-Creation-Date: 2001-04-30 18:51+0200\n"
46 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
47 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
48 "Language-Team: LANGUAGE <LL@li.org>\n"
49 "MIME-Version: 1.0\n"
50 "Content-Type: text/plain; charset=ISO-8859-1\n"
51 "Content-Transfer-Encoding: 8bit\n"
52
53 #: cogarithmetic.cc:12 cogidmarkup.cc:288 cogroman.cc:14
54 msgid "white"
55 msgstr ""
56 EOF
57
58 tmpfiles="$tmpfiles mm-u-4.po~"
59 : ${MSGMERGE=msgmerge}
60 ${MSGMERGE} -q --update --sort-output mm-u-4.po mm-u-4.pot
61 test $? = 0 || { rm -fr $tmpfiles; exit 1; }
62
63 tmpfiles="$tmpfiles mm-u-4.ok"
64 cat <<\EOF > mm-u-4.ok
65 # SOME DESCRIPTIVE TITLE.
66 # Copyright (C) YEAR Free Software Foundation, Inc.
67 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
68 #
69 msgid ""
70 msgstr ""
71 "Project-Id-Version: cog_training 1.0\n"
72 "POT-Creation-Date: 2001-04-29 22:40+0200\n"
73 "PO-Revision-Date: 2001-04-29 21:19+02:00\n"
74 "Last-Translator: Felix N. <xyz@zyx.uucp>\n"
75 "Language-Team: German <de@li.org>\n"
76 "Language: de\n"
77 "MIME-Version: 1.0\n"
78 "Content-Type: text/plain; charset=ISO-8859-1\n"
79 "Content-Transfer-Encoding: 8bit\n"
80
81 #: cogarithmetic.cc:12 cogidmarkup.cc:288 cogroman.cc:14
82 msgid "white"
83 msgstr "weiß"
84
85 #~ msgid "green"
86 #~ msgstr "grün"
87 EOF
88
89 : ${DIFF=diff}
90 ${DIFF} mm-u-4.ok mm-u-4.po
91 result=$?
92
93 rm -fr $tmpfiles
94
95 exit $result