mirror of
https://github.com/sartography/protocol-builder-mock.git
synced 2025-01-12 08:44:46 +00:00
Tests were failing because forms were not sending Q_COMPLETE data.
Added mocked Q_COMPLETE data to `add_study` and `test_add_and_edit_study`.
This commit is contained in:
parent
15dc53f957
commit
4e2b79741f
@ -57,6 +57,8 @@ class Sanity_Check_Test(unittest.TestCase):
|
||||
for r in form.requirements:
|
||||
form.data['requirements'].append(r.data)
|
||||
|
||||
form.Q_COMPLETE.data = "('No Error', 'Passed validation.')"
|
||||
|
||||
r = self.app.post('/new_study', data=form.data, follow_redirects=False)
|
||||
assert r.status_code == 302
|
||||
added_study = Study.query.filter(Study.TITLE == study_title).first()
|
||||
@ -79,6 +81,7 @@ class Sanity_Check_Test(unittest.TestCase):
|
||||
|
||||
for r in form_2.requirements:
|
||||
form_2.data['requirements'].append(r.data)
|
||||
form_2.Q_COMPLETE.data = "('No Error', 'Passed validation.')"
|
||||
|
||||
r_2 = self.app.post('/study/%i' % added_study.STUDYID, data=form_2.data, follow_redirects=False)
|
||||
assert r_2.status_code == 302
|
||||
|
Loading…
x
Reference in New Issue
Block a user