[PATCH 2 of 3] check-po: sample input
timeless at mozdev.org
timeless at mozdev.org
Sun Jun 30 03:03:42 CDT 2013
# HG changeset patch
# User timeless at mozdev.org
# Date 1372577858 14400
# Sun Jun 30 03:37:38 2013 -0400
# Node ID 1dd78724f4ee19fa047afc171e5380d01629f939
# Parent 4fbf69b0d21d0898096cae83aad33c84bec872a3
check-po: sample input
diff -r 4fbf69b0d21d -r 1dd78724f4ee tests/test-check-po.t
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/tests/test-check-po.t Sun Jun 30 03:37:38 2013 -0400
@@ -0,0 +1,29 @@
+ $ cat > rstsection.po <<EOF
+ > msgid "Main::"
+ > msgstr "Naim::"
+ >
+ > msgid "Section::"
+ > msgstr "Noictes"
+ > EOF
+ $ cat > linebreak.po <<EOF
+ > msgid "Has linebreak\\n"
+ > msgstr "Kaerbenil sah\\n"
+ >
+ > msgid "Linebreak\\n"
+ > msgstr "Nolinebreak"
+ > EOF
+ $ cat > substitutions.po <<EOF
+ > msgid "Hello %s"
+ > msgstr "%s Elloh"
+ >
+ > msgid "%s world"
+ > msgstr "%s %s"
+ >
+ > msgid "Count to %d"
+ > msgstr "%s count"
+ > EOF
+ $ check_po="$TESTDIR"/../i18n/check-po.py
+ > python "$check_po" rstsection.po linebreak.po substitutions.po
+ rstsection.po errors: rstsection: 1\r (esc)
+ linebreak.po errors: breakafter: 1\r (esc)
+ substitutions.po errors: replacements: 2\r (esc)
More information about the Mercurial-devel
mailing list