X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=gettext-tools%2Ftests%2Fxgettext-objc-1;h=9563d77745f93d6200924c8ff7c36028e587e910;hb=refs%2Fchanges%2F82%2F71082%2F1;hp=d2200edd7dec1fceb295ca054ceead7b7503858e;hpb=5d61132f836323aaf2879e04abc9d4056db248a2;p=platform%2Fupstream%2Fgettext.git diff --git a/gettext-tools/tests/xgettext-objc-1 b/gettext-tools/tests/xgettext-objc-1 index d2200ed..9563d77 100755 --- a/gettext-tools/tests/xgettext-objc-1 +++ b/gettext-tools/tests/xgettext-objc-1 @@ -1,11 +1,8 @@ #! /bin/sh +. "${srcdir=.}/init.sh"; path_prepend_ . ../src # Test ObjectiveC extractor. -tmpfiles="" -trap 'rm -fr $tmpfiles' 1 2 3 15 - -tmpfiles="$tmpfiles xg-ob-1.m" cat <<\EOF > xg-ob-1.m id str = _(@ "conca" /* comment */ @@ -28,14 +25,10 @@ _ // test NSLocalizedString(@"Information", @"") EOF -tmpfiles="$tmpfiles xg-ob-1.tmp.po xg-ob-1.po" : ${XGETTEXT=xgettext} -${XGETTEXT} --omit-header -k_ -kNSLocalizedString -d xg-ob-1.tmp xg-ob-1.m -test $? = 0 || { rm -fr $tmpfiles; exit 1; } -LC_ALL=C tr -d '\r' < xg-ob-1.tmp.po > xg-ob-1.po -test $? = 0 || { rm -fr $tmpfiles; exit 1; } +${XGETTEXT} --omit-header -k_ -kNSLocalizedString -d xg-ob-1.tmp xg-ob-1.m || exit 1 +LC_ALL=C tr -d '\r' < xg-ob-1.tmp.po > xg-ob-1.po || exit 1 -tmpfiles="$tmpfiles xg-ob-1.ok" cat <<\EOF > xg-ob-1.ok #: xg-ob-1.m:2 msgid "concatenated" @@ -62,6 +55,4 @@ EOF ${DIFF} xg-ob-1.ok xg-ob-1.po result=$? -rm -fr $tmpfiles - exit $result