diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/mailman/utilities/importer.py | 4 | ||||
| -rw-r--r-- | src/mailman/utilities/tests/test_import.py | 6 |
2 files changed, 4 insertions, 6 deletions
diff --git a/src/mailman/utilities/importer.py b/src/mailman/utilities/importer.py index 3ee2951bb..9eb0fdf35 100644 --- a/src/mailman/utilities/importer.py +++ b/src/mailman/utilities/importer.py @@ -136,14 +136,14 @@ def check_language_code(code): msg = """Missing language: {0} You must add a section describing this language in your mailman.cfg file. This section should look like this: -[language.{1}] +[language.{0}] # The English name for the language. description: CHANGE ME # And the default character set for the language. charset: utf-8 # Whether the language is enabled or not. enabled: yes -""".format(code, code[:2]) +""".format(code) raise Import21Error(msg) return code diff --git a/src/mailman/utilities/tests/test_import.py b/src/mailman/utilities/tests/test_import.py index 5a317fedb..23cf74b36 100644 --- a/src/mailman/utilities/tests/test_import.py +++ b/src/mailman/utilities/tests/test_import.py @@ -254,8 +254,7 @@ class TestBasicImport(unittest.TestCase): self._import() except Import21Error, e: # check the message - self.assertTrue("xx_XX" in str(e)) - self.assertTrue("[language.xx]" in str(e)) + self.assertTrue("[language.xx_XX]" in str(e)) else: self.fail("Import21Error was not raised") @@ -588,8 +587,7 @@ class TestRosterImport(unittest.TestCase): import_config_pck(self._mlist, self._pckdict) except Import21Error, e: # check the message - self.assertTrue("xx_XX" in str(e)) - self.assertTrue("[language.xx]" in str(e)) + self.assertTrue("[language.xx_XX]" in str(e)) else: self.fail("Import21Error was not raised") |
