Commit 689350d5 by Stephen Sanchez

Merge pull request #219 from edx/sanchez/acknowledge_submission_deadline

Acknowledge Submission Deadline
parents 9896d39f 304fab94
......@@ -177,7 +177,7 @@ class SubmissionMixin(object):
"""
workflow = self.get_workflow_info()
problem_open, date = self.is_open()
problem_open, date = self.is_open('submission')
sub_due = None
if self.submission_due is not None:
submission_deadline = dateutil.parser.parse(self.submission_due)
......
......@@ -63,3 +63,9 @@ class SubmissionTest(XBlockHandlerTestCase):
self.assertFalse(resp[0])
self.assertEqual(resp[1], "ENOPREVIEW")
self.assertEqual(resp[2], "To submit a response, view this component in Preview or Live mode.")
# In Studio preview mode, the runtime sets the user ID to None
@scenario('data/over_grade_scenario.xml', user_id='Alice')
def test_closed_submissions(self, xblock,):
resp = self.request(xblock, 'render_submission', json.dumps(dict()))
self.assertIn("Incomplete", resp)
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