Commit 84f3c33d by Daniel Friedman Committed by Diana Huang

Address doc review

parent 67fdca18
......@@ -717,9 +717,9 @@ class DataDownloadPage(PageObject):
return self.q(css='input[name=calculate-grades-csv]')
@property
def generate_weighted_problem_grade_report_button(self):
def generate_problem_grade_report_button(self):
"""
Returns the "Generate Weighted Problem Grade Report" button.
Returns the "Generate Problem Grade Report" button.
"""
return self.q(css='input[name=problem-grade-report]')
......
......@@ -387,20 +387,20 @@ class DataDownloadsTest(BaseInstructorDashboardTest):
self.verify_report_requested_event(report_name)
self.verify_report_download(report_name)
def test_weighted_problem_grade_report_download(self):
def test_problem_grade_report_download(self):
"""
Scenario: Verify that an instructor can download a weighted problem grade report
Scenario: Verify that an instructor can download a problem grade report
Given that I am an instructor
And I visit the instructor dashboard's "Data Downloads" tab
And I click on the "Generate Weighted Problem Grade Report" button
And I click on the "Generate Problem Grade Report" button
Then a report should be generated
And a report requested event should be emitted
When I click on the report
Then a report downloaded event should be emitted
"""
report_name = u"problem_grade_report"
self.data_download_section.generate_weighted_problem_grade_report_button.click()
self.data_download_section.generate_problem_grade_report_button.click()
self.data_download_section.wait_for_available_report()
self.verify_report_requested_event(report_name)
self.verify_report_download(report_name)
......@@ -1956,7 +1956,7 @@ def calculate_grades_csv(request, course_id):
@require_level('staff')
def problem_grade_report(request, course_id):
"""
Request a CSV showing students' weighted grades for all problems in the
Request a CSV showing students' grades for all problems in the
course.
AlreadyRunningError is raised if the course's grades are already being
......@@ -1965,13 +1965,11 @@ def problem_grade_report(request, course_id):
course_key = SlashSeparatedCourseKey.from_deprecated_string(course_id)
try:
instructor_task.api.submit_problem_grade_report(request, course_key)
# TODO: verify copy with documentation team
success_status = _("Your weighted problem report is being generated! "
success_status = _("Your problem grade report is being generated! "
"You can view the status of the generation task in the 'Pending Instructor Tasks' section.")
return JsonResponse({"status": success_status})
except AlreadyRunningError:
# TODO: verify copy with documentation team
already_running_status = _("A weighted problem generation task is already in progress. "
already_running_status = _("A problem grade report is already being generated. "
"Check the 'Pending Instructor Tasks' table for the status of the task. "
"When completed, the report will be available for download in the table below.")
return JsonResponse({
......
......@@ -337,7 +337,7 @@ def submit_calculate_grades_csv(request, course_key):
def submit_problem_grade_report(request, course_key):
"""
Submits a task to generate a CSV grade report containing weighted problem
Submits a task to generate a CSV grade report containing problem
values.
"""
task_type = 'grade_problems'
......
......@@ -159,7 +159,7 @@ def calculate_grades_csv(entry_id, xmodule_instance_args):
@task(base=BaseInstructorTask, routing_key=settings.GRADES_DOWNLOAD_ROUTING_KEY) # pylint: disable=not-callable
def calculate_problem_grade_report(entry_id, xmodule_instance_args):
"""
Generate a CSV for a course containing all students' weighted problem
Generate a CSV for a course containing all students' problem
grades and push the results to an S3 bucket for download.
"""
# Translators: This is a past-tense phrase that is inserted into task progress messages as {action}.
......
......@@ -271,7 +271,7 @@ class TestInstructorGradeReport(TestReportMixin, InstructorTaskCourseTestCase):
class TestProblemGradeReport(TestReportMixin, InstructorTaskModuleTestCase):
"""
Test that the weighted problem CSV generation works.
Test that the problem CSV generation works.
"""
def setUp(self):
super(TestProblemGradeReport, self).setUp()
......
......@@ -112,7 +112,7 @@ class DataDownload
@onClickGradeDownload @$calculate_grades_csv_btn, gettext("Error generating grades. Please try again.")
@$problem_grade_report_csv_btn.click (e) =>
@onClickGradeDownload @$problem_grade_report_csv_btn, gettext("Error generating weighted problem report. Please try again.")
@onClickGradeDownload @$problem_grade_report_csv_btn, gettext("Error generating problem grade report. Please try again.")
onClickGradeDownload: (button, errorMessage) ->
# Clear any CSS styling from the request-response areas
......
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