| @@ 286-297 (lines=12) @@ | ||
| 283 | ||
| 284 | self.assertTrue(my_excel.called) |
|
| 285 | ||
| 286 | @patch.dict( |
|
| 287 | "excel.helpers.exceltemplate.TEMPLATE_COLUMNS", |
|
| 288 | {'breed': ["a column"]}) |
|
| 289 | @patch('submissions.views.ImportTemplateTask.delay') |
|
| 290 | def test_template_issues_in_columns(self, my_task): |
|
| 291 | # submit a template file |
|
| 292 | response = self.client.post( |
|
| 293 | self.url, |
|
| 294 | self.get_data(ds_file=TEMPLATE_TYPE)) |
|
| 295 | ||
| 296 | # check errors |
|
| 297 | self.common_check(response, my_task) |
|
| 298 | ||
| 299 | @patch('submissions.views.ImportCRBAnimTask.delay') |
|
| 300 | @patch('submissions.views.ImportTemplateTask.delay') |
|
| @@ 255-266 (lines=12) @@ | ||
| 252 | ||
| 253 | self.assertTrue(my_excel.called) |
|
| 254 | ||
| 255 | @patch.dict( |
|
| 256 | "excel.helpers.exceltemplate.TEMPLATE_COLUMNS", |
|
| 257 | {'breed': ["a column"]}) |
|
| 258 | @patch('submissions.views.ImportTemplateTask.delay') |
|
| 259 | def test_template_issues_in_columns(self, my_task): |
|
| 260 | # submit a template file |
|
| 261 | response = self.client.post( |
|
| 262 | self.url, |
|
| 263 | self.get_data(ds_file=TEMPLATE_TYPE)) |
|
| 264 | ||
| 265 | # check errors |
|
| 266 | self.common_check(response, my_task) |
|
| 267 | ||
| 268 | ||
| 269 | class CRBAnimReloadSubmissionViewTest( |
|