summaryrefslogtreecommitdiffstats
path: root/gettext-tools/tests
diff options
context:
space:
mode:
authorDaiki Ueno <ueno@gnu.org>2014-12-04 18:38:44 +0900
committerDaiki Ueno <ueno@gnu.org>2014-12-04 18:38:44 +0900
commit6194e04bc89968548d4e7fcefffcfe65cce0fafb (patch)
treeb4eadc6ea93f97f942723f0ad1f22cda43a200f6 /gettext-tools/tests
parent976ea8956e68307ec73678f8a07ea6eb7308253f (diff)
downloadexternal_gettext-6194e04bc89968548d4e7fcefffcfe65cce0fafb.zip
external_gettext-6194e04bc89968548d4e7fcefffcfe65cce0fafb.tar.gz
external_gettext-6194e04bc89968548d4e7fcefffcfe65cce0fafb.tar.bz2
tests: Improve test coverage of GSettings scanner
* xgettext-gsettings-1: Check empty string and multiline comment.
Diffstat (limited to 'gettext-tools/tests')
-rw-r--r--gettext-tools/tests/ChangeLog5
-rwxr-xr-xgettext-tools/tests/xgettext-gsettings-116
2 files changed, 16 insertions, 5 deletions
diff --git a/gettext-tools/tests/ChangeLog b/gettext-tools/tests/ChangeLog
index faa6e3b..d16ccae 100644
--- a/gettext-tools/tests/ChangeLog
+++ b/gettext-tools/tests/ChangeLog
@@ -1,3 +1,8 @@
+2014-12-04 Daiki Ueno <ueno@gnu.org>
+
+ tests: Improve test coverage of GSettings scanner
+ * xgettext-gsettings-1: Check empty string and multiline comment.
+
2014-12-03 Daiki Ueno <ueno@gnu.org>
* msgunfmt-3: Locate overflow.mo in $abs_srcdir instead of '..'.
diff --git a/gettext-tools/tests/xgettext-gsettings-1 b/gettext-tools/tests/xgettext-gsettings-1
index fbc9b6e..387f476 100755
--- a/gettext-tools/tests/xgettext-gsettings-1
+++ b/gettext-tools/tests/xgettext-gsettings-1
@@ -21,18 +21,21 @@ cat <<EOF > xg-gs-1.gschema.xml
<schema id="org.gnome.example" path="/org/gnome/example/">
<key name="foo" type="i">
<default>0</default>
- <summary context="Foo">Example Integer Key</summary>
+ <!-- This is the first line.
+ This is the second line. -->
+ <summary>Example Integer Key</summary>
<description>
The example integer key to test that the default value is not
translated.
</description>
</key>
<key name="bar" type="s">
- <default l10n="messages">
+ <default l10n="messages" context="Foo">
' foo bar baz'
</default>
</key>
<key name="baz" type="s">
+ <default l10n="messages" context="Baz"></default>
<summary context="Baz"></summary>
</key>
</schema>
@@ -61,16 +64,19 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
-#: xg-gs-1.gschema.xml:6
+#. This is the first line.
+#. This is the second line.
+#: xg-gs-1.gschema.xml:8
msgid "Example Integer Key"
msgstr ""
-#: xg-gs-1.gschema.xml:7
+#: xg-gs-1.gschema.xml:9
msgid ""
"The example integer key to test that the default value is not translated."
msgstr ""
-#: xg-gs-1.gschema.xml:13
+#: xg-gs-1.gschema.xml:15
+msgctxt "Foo"
msgid "' foo bar baz'"
msgstr ""
EOF