diff --git a/tests/regressiontests/i18n/commands/extraction.py b/tests/regressiontests/i18n/commands/extraction.py
index 4f47634..e380bfc 100755
a
|
b
|
class NoWrapExtractorTests(ExtractorTests):
|
183 | 183 | self.assertTrue(os.path.exists(self.PO_FILE)) |
184 | 184 | po_contents = open(self.PO_FILE, 'r').read() |
185 | 185 | self.assertMsgId('""\n"This literal should also be included wrapped or not wrapped depending on the "\n"use of the --no-wrap option."', po_contents, use_quotes=False) |
| 186 | |
| 187 | class KeepPotFileExtractorTests(ExtractorTests): |
| 188 | |
| 189 | def tearDown(self): |
| 190 | POT_FILE = self.PO_FILE + 't' |
| 191 | super(KeepPotFileExtractorTests, self).tearDown() |
| 192 | os.chdir(self.test_dir) |
| 193 | try: |
| 194 | os.unlink(POT_FILE) |
| 195 | except OSError: |
| 196 | pass |
| 197 | os.chdir(self._cwd) |
| 198 | |
| 199 | def test_keep_pot_disabled_by_default(self): |
| 200 | POT_FILE = self.PO_FILE + 't' |
| 201 | os.chdir(self.test_dir) |
| 202 | management.call_command('makemessages', locale=LOCALE, verbosity=0) |
| 203 | self.assertFalse(os.path.exists(POT_FILE)) |
| 204 | |
| 205 | def test_keep_pot_enabled(self): |
| 206 | POT_FILE = self.PO_FILE + 't' |
| 207 | os.chdir(self.test_dir) |
| 208 | management.call_command('makemessages', locale=LOCALE, verbosity=0, keep_pot=True) |
| 209 | self.assertTrue(os.path.exists(POT_FILE)) |
| 210 | |