Generalize grade report to allow display of any report
We would like to be able to generate arbitrary reports and expose them to the instructor by simply uploading them to S3. The existing grade download infrastructure pretty much supported that already, however, all of the internal and external structures were referring to the reports as exclusively grading related. Fixes: AN-590
This commit is contained in:
@@ -130,7 +130,7 @@ class TestInstructorAPIDenyLevels(ModuleStoreTestCase, LoginEnrollmentTestCase):
|
||||
('send_email', {'send_to': 'staff', 'subject': 'test', 'message': 'asdf'}),
|
||||
('list_instructor_tasks', {}),
|
||||
('list_background_email_tasks', {}),
|
||||
('list_grade_downloads', {}),
|
||||
('list_report_downloads', {}),
|
||||
('calculate_grades_csv', {}),
|
||||
]
|
||||
# Endpoints that only Instructors can access
|
||||
@@ -794,9 +794,9 @@ class TestInstructorAPILevelsDataDump(ModuleStoreTestCase, LoginEnrollmentTestCa
|
||||
self.assertTrue(body.startswith('"User ID","Anonymized user ID"\n"2","42"\n'))
|
||||
self.assertTrue(body.endswith('"7","42"\n'))
|
||||
|
||||
def test_list_grade_downloads(self):
|
||||
url = reverse('list_grade_downloads', kwargs={'course_id': self.course.id})
|
||||
with patch('instructor_task.models.LocalFSGradesStore.links_for') as mock_links_for:
|
||||
def test_list_report_downloads(self):
|
||||
url = reverse('list_report_downloads', kwargs={'course_id': self.course.id})
|
||||
with patch('instructor_task.models.LocalFSReportStore.links_for') as mock_links_for:
|
||||
mock_links_for.return_value = [
|
||||
('mock_file_name_1', 'https://1.mock.url'),
|
||||
('mock_file_name_2', 'https://2.mock.url'),
|
||||
|
||||
Reference in New Issue
Block a user