From 44bce70de3a7d3c2787d0d5cb0b452b5191b38fd Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Tue, 22 Mar 2011 21:14:15 -0700 Subject: [PATCH] i18n: Test converting between unknown encodings too. This would have found the bug fixed by the previous commit. --- tests/libpspp/i18n.at | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/libpspp/i18n.at b/tests/libpspp/i18n.at index 5444a78f..421241e5 100644 --- a/tests/libpspp/i18n.at +++ b/tests/libpspp/i18n.at @@ -55,6 +55,14 @@ dnl So it should exercise the E2BIG case CHECK_I18N_RECODE([from ISO-8859-1 to UTF-8 with overflow], [ISO-8859-1], [UTF-8], [Tsch\374\337!], [Tsch\303\274\303\237!]) + +AT_SETUP([convert unknown encoding]) +AT_KEYWORDS([i18n]) +AT_CHECK([i18n-test recode nonexistent1 nonexistent2 asdf], [0], [asdf +], + [Warning: cannot create a converter for `nonexistent1' to `nonexistent2': Invalid argument +]) +AT_CLEANUP AT_BANNER([i18n concatenation]) -- 2.30.2