diff options
author | Rogelio Mita <rogeliomita@activitycentral.com> | 2013-09-26 14:28:17 (GMT) |
---|---|---|
committer | Rogelio Mita <rogeliomita@activitycentral.com> | 2013-09-26 14:28:17 (GMT) |
commit | f4f449f40affe15ab4ba572283cd206537565578 (patch) | |
tree | 85eb464cd14cf5aa911766b88eb348ca845801a7 /webapp/polls/tests/structure_tests.py | |
parent | 8767b61a5686a05292942c764f1eb16a499878ab (diff) |
Moving test_it_should_be_read_only_when_poll_has_results to separate class for read_only status of a structure
Diffstat (limited to 'webapp/polls/tests/structure_tests.py')
-rw-r--r-- | webapp/polls/tests/structure_tests.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/webapp/polls/tests/structure_tests.py b/webapp/polls/tests/structure_tests.py index aeb8702..ba30c91 100644 --- a/webapp/polls/tests/structure_tests.py +++ b/webapp/polls/tests/structure_tests.py @@ -314,6 +314,14 @@ class StructureTests(MongoTestCase): def test_it_should_respond_to_ready_only_msg(self): self.assertTrue(hasattr(Structure, 'READ_ONLY_MSG')) + +class ReadOnlyTest(MongoTestCase): + + def setUp(self): + poll = Poll({"name": "poll name"}) + poll_id = poll.save() + self.poll = poll.get(poll_id) + def test_it_should_be_read_only_when_poll_has_results(self): poll = self.poll structure = Structure(data={}, poll=poll) |