No empty .Rs/.Re
[netbsd-mini2440.git] / gnu / dist / gettext / gettext-tools / tests / msgmerge-4
blobd9cc1e83c6f97ea206404da2208cc4d7224f6007
1 #! /bin/sh
3 # Test handling of comments.
5 tmpfiles=""
6 trap 'rm -fr $tmpfiles' 1 2 3 15
8 tmpfiles="$tmpfiles mm-test4.in1.po mm-test4.in2.po"
9 cat <<EOF > mm-test4.in1.po
10 msgid "one"
11 msgstr "eins"
12 # This comment should be copied.
13 msgid "two"
14 msgstr "zwei"
17 # And this one, too.
18 #~ msgid "four"
19 #~ msgstr "vier"
20 EOF
22 cat <<EOF > mm-test4.in2.po
23 msgid "one"
24 msgstr ""
25 # This is a comment in the POT file.
26 msgid "three"
27 msgstr ""
28 EOF
30 tmpfiles="$tmpfiles mm-test4.out"
31 : ${MSGMERGE=msgmerge}
32 ${MSGMERGE} -q mm-test4.in1.po mm-test4.in2.po -o mm-test4.out
33 test $? = 0 || { rm -fr $tmpfiles; exit 1; }
35 tmpfiles="$tmpfiles mm-test4.ok"
36 cat <<EOF > mm-test4.ok
37 msgid "one"
38 msgstr "eins"
40 # This is a comment in the POT file.
41 msgid "three"
42 msgstr ""
44 # This comment should be copied.
45 #~ msgid "two"
46 #~ msgstr "zwei"
48 # And this one, too.
49 #~ msgid "four"
50 #~ msgstr "vier"
51 EOF
53 : ${DIFF=diff}
54 ${DIFF} mm-test4.ok mm-test4.out
55 result=$?
57 rm -fr $tmpfiles
59 exit $result