canvas-lms/config
Jeremy Neander c03ea6647b add bulk selection for provisional grades
closes GRADE-1480

test plan:
 A. Setup
    1. Create a published course
    2. Enroll one teacher
    3. Enroll two TAs
    4. Enroll three students
    5. Create a moderated assignment
       * with Teacher as final grader

    6. As the first TA:
       a. Visit SpeedGrader for the assignment
       b. Grade Student 1
       c. Grade Student 2

    7. As the second TA:
       a. Visit SpeedGrader for the assignment
       b. Grade Student 2
       c. Grade Student 3

    8. Open the Rails console
    9. Note these attributes of the provisional grades:
       * `id` (provisional grade id)
       * `user_id` (student id)
       * `scorer_id` (grader id)

       assignment = Assignment.find(:id)
       assignment.pluck(:id, :user_id, :scorer_id)

 B. Verification without Anonymity
    * To test bulk selection, send a PUT request to:

       /api/v1/courses/:course_id/assignments/:assignment_id/
         ↪ provisional_grades/bulk_select

       * Use a session for the final grader
       * Include in the request body an object as follows:
         {provisional_grade_ids: […]}
       * The array will contain some of the provisional grade ids
         noted from the Rails console
       * The response will include an array of objects as follows:

         {
           "assignment_id": "1",
           "selected_provisional_grade_id": "2",
           "student_id": "3"
         }

    * To verify grade selection:
       a. Log in or act as the Teacher
       b. Visit the moderation page for the assignment
       c. Verify the intended grades have been selected
    * Each of the following steps will be done in sequence without
      resetting anything to a prior state

    1. Bulk select the following grades:
       * TA-1's grade for Student 1
       * TA-2's grade for Student 2
    2. Verify the JSON includes the following grades:
       * TA-1's grade for Student 1
       * TA-2's grade for Student 2
    3. Verify the following grades are selected:
       * TA-1's grade for Student 1
       * TA-2's grade for Student 2

    4. Bulk select the following grades:
       * TA-1's grade for Student 2
       * TA-2's grade for Student 3
    5. Verify the JSON includes the following grades:
       * TA-1's grade for Student 2
       * TA-2's grade for Student 3
    6. Verify the following grades are selected:
       * TA-1's grade for Student 1
       * TA-1's grade for Student 2
       * TA-2's grade for Student 3

    7. Bulk select the following grades (listed in this order):
       * TA-1's grade for Student 1
       * TA-2's grade for Student 3
       * TA-1's grade for Student 3
    8. Verify the JSON includes the following grades:
       * TA-1's grade for Student 3
    9. Verify the following grades are selected:
       * TA-1's grade for Student 1
       * TA-1's grade for Student 2
       * TA-1's grade for Student 3

 B. Verification with Anonymity
    1. Enable anonymous grading for the assignment
    2. Bulk select the following grades:
       * TA-2's grade for Student 2
       * TA-2's grade for Student 3
    3. Verify the JSON includes "anonymous_id"
    4. Verify the JSON excludes "student_id"

e1d4b3ee4d

Change-Id: I51190808a9dfd321c6110f50d6d0e4661fa86c1c
Reviewed-on: https://gerrit.instructure.com/161215
Reviewed-by: Adrian Packel <apackel@instructure.com>
Tested-by: Jenkins
Reviewed-by: Gary Mei <gmei@instructure.com>
QA-Review: James Butters <jbutters@instructure.com>
Product-Review: Keith T. Garner <kgarner@instructure.com>
2018-08-20 18:29:13 +00:00
..
environments enforce Bullet in specs 2018-08-10 17:28:44 +00:00
initializers fix creating new shards from scratch 2018-08-15 23:33:46 +00:00
locales update zh-Hant translation 2018-08-18 05:40:35 -06:00
saml add first class support for the UK Federation 2017-08-08 20:26:52 +00:00
amazon_s3.yml.example aws sdk v2 support for attachments 2017-01-24 21:09:14 +00:00
application.rb rails 5.2: enforce raw sql for order by 2018-08-08 17:31:14 +00:00
boot.rb Revert "Speed up boot time with bootsnap" 2017-05-22 23:24:32 +00:00
bounce_notifications.yml.example convert bounce notification processor to aws sdk v2 2016-12-13 19:33:43 +00:00
brakeman.ignore fix supported contexts in files#api_capture 2018-03-11 18:56:01 +00:00
brandable_css.yml make feature flags for Right To Left layout 2018-03-21 21:09:38 +00:00
browsers.yml update browsers in browsers.yml - to the safest level 2016-07-15 21:23:33 +00:00
cache_store.yml.example remove redis_store from test env 2017-09-20 15:42:09 +00:00
canvas_cdn.yml.example convert CDN uploader to AWS SDK v2 2016-12-19 23:43:06 +00:00
canvas_rails5.rb drop rails 5.0 2018-03-20 19:50:23 +00:00
cassandra.yml.example improve cassandra documentation 2017-09-29 19:28:08 +00:00
conditional_release.yml.example add functionality to get rules affecting an assignment 2016-10-06 18:51:07 +00:00
consul.yml.example Add dc config to jwk set_keys 2018-08-10 17:44:48 +00:00
copyright-template.js [eslint] have --fix add copyright header for you 2018-02-15 20:01:41 +00:00
cutycapt.yml.example
database.yml.example remove queue from production database.yml.example 2016-01-26 18:07:23 +00:00
database.yml.travis Added .travis.yml 2014-01-15 20:30:11 +00:00
delayed_jobs.yml.example allow enabling inst-jobs health checks 2018-05-11 19:22:32 +00:00
domain.yml.example api: translate absolute paths to full urls with the canvas host 2012-07-02 09:53:59 -06:00
dynamic_settings.yml.example update example lti keypairs 2018-07-12 20:35:06 +00:00
environment.rb da licença part 23 2017-04-27 21:51:35 +00:00
external_migration.yml.example allow migrations to work across job servers 2011-02-07 15:07:49 -07:00
file_store.yml.example api: translate absolute paths to full urls with the canvas host 2012-07-02 09:53:59 -06:00
incoming_mail.yml.example improve robustness of incoming message processor 2013-04-29 14:47:09 +00:00
jslint.conf make jslint settings more sane 2012-08-17 11:04:40 -06:00
linked_in.yml.example
logging.yml.example allow setting the log level in logging.yml for syslog 2012-09-13 09:55:09 -06:00
marginalia.yml.example record migration name in marginalia comment 2016-03-09 04:00:47 +00:00
memcache.yml.example support redis as well as memcache for a rails cache store 2011-07-20 14:59:03 -06:00
notification_failures.yml.example convert notification_failure_processor to aws sdk v2 2016-12-16 18:47:48 +00:00
notification_service.yml.example convert notification service to AWS SDK v2 2016-10-31 17:44:57 +00:00
offline_web.yml.sample add canvas_offline_course_viewer to export package 2017-01-23 20:25:08 +00:00
outgoing_mail.yml.example add multiple reply-to support to outgoing mail. 2013-02-22 14:02:27 -07:00
periodic_jobs.yml.example allow overriding periodic jobs schedules 2012-02-01 14:01:28 -07:00
puma.rb Add copyright message to remaining .rb files 2018-03-19 13:38:50 +00:00
raven.yml.example get sentry into canvas 2015-04-13 22:26:15 +00:00
redis.yml.example spec: enable redis on travis 2014-01-16 22:03:30 +00:00
routes.rb add bulk selection for provisional grades 2018-08-20 18:29:13 +00:00
saml.yml.example support multiple SAML private keys for decryption 2013-03-15 14:31:57 -06:00
security.yml.example LTI 1.3: Add security claims and sign with Canvas private key 2018-08-09 21:33:03 +00:00
selenium.yml.example add blueprint setting options to the course settings page 2017-06-02 23:07:51 +00:00
session_store.yml.example update the example session_store.yml 2014-01-21 02:15:18 +00:00
statsd.yml.example optionally don't append hostname to statsd keys 2013-04-04 19:14:49 +00:00
styleguide.yml force add config files that didn't make it 2013-04-10 18:50:05 +00:00
testrail.yml.example adding tests, plus testrail reporting 2014-07-31 16:32:16 +00:00
twilio.yml.example Send messages via Twilio 2015-09-14 15:46:23 +00:00
twitter.yml.example