1#! /bin/sh
2. "${srcdir=.}/init.sh"; path_prepend_ . ../src
3
4# Test --update: location changed, and xgettext comment added. Both changes
5# must be reflected in the resulting PO file. With Java .properties syntax.
6
7cat <<\EOF > mm-p-2.po
8#: cogarithmetic.cc:12
9white=wei\u00df
10EOF
11
12cat <<EOF > mm-p-2.pot
13#. location changed
14#: cogarithmetic.cc:33
15!white=
16EOF
17
18: ${MSGMERGE=msgmerge}
19${MSGMERGE} -q --properties-input --update mm-p-2.po mm-p-2.pot || Exit 1
20mv mm-p-2.po mm-p-2.tmp || { Exit 1; }
21LC_ALL=C tr -d '\r' < mm-p-2.tmp > mm-p-2.po || Exit 1
22
23cat <<\EOF > mm-p-2.ok
24#. location changed
25#: cogarithmetic.cc:33
26white=wei\u00df
27EOF
28
29: ${DIFF=diff}
30${DIFF} mm-p-2.ok mm-p-2.po
31result=$?
32
33exit $result
34