Commit 7e05c3fd authored by Michal Čihař's avatar Michal Čihař

Test that validation works on corrupted storage

Signed-off-by: default avatarMichal Čihař <michal@cihar.com>
parent a569757a
...@@ -600,6 +600,10 @@ class SubProjectErrorTest(RepoTestCase): ...@@ -600,6 +600,10 @@ class SubProjectErrorTest(RepoTestCase):
ParseError, ParseError,
lambda: translation.store lambda: translation.store
) )
self.assertRaises(
ValidationError,
translation.clean
)
def test_invalid_template_storage(self): def test_invalid_template_storage(self):
testfile = os.path.join(self.component.get_path(), 'ts-mono', 'en.ts') testfile = os.path.join(self.component.get_path(), 'ts-mono', 'en.ts')
...@@ -613,6 +617,10 @@ class SubProjectErrorTest(RepoTestCase): ...@@ -613,6 +617,10 @@ class SubProjectErrorTest(RepoTestCase):
ParseError, ParseError,
lambda: self.component.template_store lambda: self.component.template_store
) )
self.assertRaises(
ValidationError,
self.component.clean
)
class SubProjectEditTest(ViewTestCase): class SubProjectEditTest(ViewTestCase):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment