diff options
author | Jeremy Kerr <jk@ozlabs.org> | 2015-06-05 14:32:26 +0800 |
---|---|---|
committer | Jeremy Kerr <jk@ozlabs.org> | 2015-06-05 14:37:09 +0800 |
commit | 46e4ad955a2a7ba4f32b76a74b350140a1e3d761 (patch) | |
tree | 02892290f921f567d1778aa11ee1168e2e7c980a /patchwork/tests/test_patchparser.py | |
parent | 7a39d75859c4ee908573726f0a82df85cdb8b845 (diff) | |
download | patchwork-46e4ad955a2a7ba4f32b76a74b350140a1e3d761.tar.bz2 patchwork-46e4ad955a2a7ba4f32b76a74b350140a1e3d761.tar.xz |
patchwork: Explicitly load states fixtures
Apps with migrations will no longer load the initial_data fixtures by
default. In order to prepare to add migrations to patchwork, rename the
initial_data fixture to default_states (to match the default_tags
fixture), and explicitly load them in tests that require them.
Also, include this step in the INSTALL document.
Signed-off-by: Jeremy Kerr <jk@ozlabs.org>
Diffstat (limited to 'patchwork/tests/test_patchparser.py')
-rw-r--r-- | patchwork/tests/test_patchparser.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/patchwork/tests/test_patchparser.py b/patchwork/tests/test_patchparser.py index da2b07a..58689bb 100644 --- a/patchwork/tests/test_patchparser.py +++ b/patchwork/tests/test_patchparser.py @@ -32,6 +32,7 @@ except ImportError: from email.MIMEText import MIMEText class PatchTest(TestCase): + fixtures = ['default_states'] default_sender = defaults.sender default_subject = defaults.subject project = defaults.project @@ -246,6 +247,7 @@ class MultipleProjectPatchTest(TestCase): """ Test that patches sent to multiple patchwork projects are handled correctly """ + fixtures = ['default_states'] test_comment = 'Test Comment' patch_filename = '0001-add-line.patch' msgid = '<1@example.com>' @@ -449,6 +451,7 @@ class NoNewlineAtEndOfFilePatchTest(MBoxPatchTest): self.assertEqual(2, patch.content.count('\ No newline at end of file')) class DelegateRequestTest(TestCase): + fixtures = ['default_states'] patch_filename = '0001-add-line.patch' msgid = '<1@example.com>' invalid_delegate_email = "nobody" @@ -494,6 +497,7 @@ class DelegateRequestTest(TestCase): self.user.delete() class InitialPatchStateTest(TestCase): + fixtures = ['default_states'] patch_filename = '0001-add-line.patch' msgid = '<1@example.com>' invalid_state_name = "Nonexistent Test State" @@ -558,7 +562,7 @@ class ParseInitialTagsTest(PatchTest): test_comment = ('test comment\n\n' + 'Tested-by: Test User <test@example.com>\n' + 'Reviewed-by: Test User <test@example.com>\n') - fixtures = ['default_tags'] + fixtures = ['default_tags', 'default_states'] def setUp(self): project = defaults.project |