make sure FOR UPDATE queries are on master

Change-Id: I89874d260cffbfa749779345b942a29a11e14b22
Reviewed-on: https://gerrit.instructure.com/23742
Reviewed-by: Brian Palmer <brianp@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Cody Cutrer <cody@instructure.com>
fix upcoming_events on slave

Change-Id: I638038c1ab50af816ab28b66a79c2be2696a5079
Reviewed-on: https://gerrit.instructure.com/23743
Reviewed-by: Brian Palmer <brianp@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Tested-by: Cody Cutrer <cody@instructure.com>
adds aria-describedby to matching question distractor input

fixes CNVS-6550
This adds the aria-describedby to the textarea input for matching
question distractors, to solve accessibility problems.

Change-Id: Ia093a99f92e3d4b77f9a9cc65a91d9364a35949a
Reviewed-on: https://gerrit.instructure.com/23614
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Derek DeVries <ddevries@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
Product-Review: Josh Simpson <jsimpson@instructure.com>
add support for kaltura analytics to media player

Adds an option to kaltura plugin config to enable kaltura
analytics tracking.

Test Plan:
 * Enable the analytics tracking in the kaltura plugin settings
 * Tail the event logs on the kaltura app servers as you watch videos
 * The events should be logged
 * Also test in IE9 to make sure session cookie is properly set

closes CNVS-7252

Change-Id: Ic7241404e840bdd6a16f344da42053c969850a46
Reviewed-on: https://gerrit.instructure.com/23266
QA-Review: Hannah Bottalla <hannah@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Mark Severson <markse@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
use common stylesheets everywhere they're needed, fixes CNVS-7736

test plan
1. load up canvas
2. it should look ok
3. go to /register
4. it should look ok

Change-Id: I582d334a743364454f81a9f7a5ca4b3145b821cd
Reviewed-on: https://gerrit.instructure.com/23746
Reviewed-by: Landon Wilkins <lwilkins@instructure.com>
Reviewed-by: Mark Ericksen <marke@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Marc LeGendre <marc@instructure.com>
QA-Review: Marc LeGendre <marc@instructure.com>
add aria-labels to unclear question group form elements

fixes CNVS-6540
this adds aria-labels to a compact set of form elements in the question
group form.

Change-Id: I2186eb2e499527b8fa5aab0339bcc925c8d419fe
Reviewed-on: https://gerrit.instructure.com/23637
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Derek DeVries <ddevries@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
Product-Review: Josh Simpson <jsimpson@instructure.com>
fix quiz regrading in production environments

Fixes a bug where the way DelayedJob would set up the quiz regrading job
would find the quiz by its id, not by the passed "version" of the quiz
(which was acquired by quiz.versions.first.model).

Also makes QuizRegrader take a hash for the constructor instead of
separate arguments due to the many combinations of options.

QuizRegrades now always happen in a delayed job, regardless of which
environment Canvas is running in.

test plan:
  - in a production environment, test quiz regrading
  - it should update the student view and teacher views

fixes CNVS-7639

Change-Id: If0ba155f8b285c4f66c4ffec010bef2c973e1001
Reviewed-on: https://gerrit.instructure.com/23745
Reviewed-by: Derek DeVries <ddevries@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Stanley Stuart <stanley@instructure.com>
add additional params to help error reports

refs PS-325

Change-Id: I0d089f9e2081c71bb35240dd82c77139c4e71577
Reviewed-on: https://gerrit.instructure.com/23641
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Duane Johnson <duane@instructure.com>
Reviewed-by: Mark Ericksen <marke@instructure.com>
Product-Review: Adam Phillipps <adam@instructure.com>
QA-Review: Adam Phillipps <adam@instructure.com>
strand up ContextModule#update_downstreams

Change-Id: Ifbfac378e96a89688591225f91d084f107d601a9
Reviewed-on: https://gerrit.instructure.com/23762
Reviewed-by: Zach Wily <zach@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
Product-Review: Brian Palmer <brianp@instructure.com>
QA-Review: Brian Palmer <brianp@instructure.com>
Tested-by: Brian Palmer <brianp@instructure.com>
change "awhile" to "a while" on sis import page

test plan:
1. go to sis import page on an account
2. import a csv (it will be easier if you have a large csv)
3. once the csv is importing, you should see the import mesage below -
verify it says "this may take a while".

closes: CNVS-7771

Change-Id: I5e02ee24e9c71aeefb8772c58b446028889e278a
Reviewed-on: https://gerrit.instructure.com/23773
Reviewed-by: James Williams  <jamesw@instructure.com>
Product-Review: James Williams  <jamesw@instructure.com>
QA-Review: James Williams  <jamesw@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
fix fragile specs

fixes CNVS-7719

Change-Id: I4e73c6cb1937e0cbb53df26d73de3394bb9a417e
Reviewed-on: https://gerrit.instructure.com/23760
Reviewed-by: Bryan Madsen <bryan@instructure.com>
Product-Review: Bryan Madsen <bryan@instructure.com>
QA-Review: Bryan Madsen <bryan@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
send the assignment_group_id through "more options"

fixes CNVS-7712

test plan:
- create a few different assignment groups
- start creating an assignmet in them from the index page, and then hit more
  options
- the correct assignment group should be selected on the full edit page

Change-Id: Ib85031ea94c6c92b58407b42bb443f0d2fc3d3ba
Reviewed-on: https://gerrit.instructure.com/23678
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Amber Taniuchi <amber@instructure.com>
Reviewed-by: Cameron Sutter <csutter@instructure.com>
Product-Review: Simon Williams <simon@instructure.com>
Revert "change "awhile" to "a while" on sis import page"

This reverts commit d940d5a3cf5ccf00e9baa5b82e3d457904537956.

Change-Id: I1fcebbebd5bdef338f634232f4a52074fca452a5
Reviewed-on: https://gerrit.instructure.com/23778
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: James Williams  <jamesw@instructure.com>
Product-Review: James Williams  <jamesw@instructure.com>
QA-Review: James Williams  <jamesw@instructure.com>
write report file object on master

fixes CNVS-7775

test plan
- run an account report 
- report should work

Change-Id: I96bcadd05b704247fb9b0b79ad30f8f36896d592
Reviewed-on: https://gerrit.instructure.com/23787
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
QA-Review: Rob Orton <rob@instructure.com>
create progressions on the master

Change-Id: Ia55a449117242f88a6d90ca4647efd5380476e37
Reviewed-on: https://gerrit.instructure.com/23791
Reviewed-by: Brian Palmer <brianp@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
fix join query with find_each

fixes CNVS-7767

test plan
 - run sis import in batch mode
 - should remove enrollments not included for term

Change-Id: I556c4fdf6dc093da61a86322f69d3be3175a803c
Reviewed-on: https://gerrit.instructure.com/23772
Reviewed-by: Cody Cutrer <cody@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
QA-Review: Jeremy Putnam <jeremyp@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
show rubrics as aligned items to outcomes

fixes CNVS-7272

test plan:
- create a rubric with an outcome
- go to the outcome page, you should see the rubric listed as an aligned item
- try to delete the outcome
  it should fail
- remove the outcome from the rubric
- go back to the outcome page, and the rubric should no longer be listed as
  aligned
- try to delete the outcome again
- it should succeed
- also try this with outcomes imported from accounts

Change-Id: I3242befc987e2b92f98125cbfb6d32f293cdb9d1
Reviewed-on: https://gerrit.instructure.com/23531
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Amber Taniuchi <amber@instructure.com>
Reviewed-by: Cameron Matheson <cameron@instructure.com>
Product-Review: Simon Williams <simon@instructure.com>
spec: external tools delayed jobs modal dialog fix

Change-Id: I8db4117a33ad17c3f914ed1696ce5e7008bb1e03
Reviewed-on: https://gerrit.instructure.com/23675
Reviewed-by: Bryan Madsen <bryan@instructure.com>
Product-Review: Bryan Madsen <bryan@instructure.com>
QA-Review: Bryan Madsen <bryan@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
fix javascript unit tests

Prefer using sinon's fakeTimers to using setTimeout, increase
the amount of time for events to fire for PhantomJS, and use $.simluate
to trigger 'click' events so we have tighter control of the browser's
event loop.

Change-Id: I2fa2ee941f884fcc5e4f312f6400d22ff65b9138
Reviewed-on: https://gerrit.instructure.com/23841
Reviewed-by: Jacob Fugal <jacob@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Stanley Stuart <stanley@instructure.com>
QA-Review: Stanley Stuart <stanley@instructure.com>
fix database migrations for quiz regrades

test plan:
  bundle exec rake db:migrate should work
  test plan for quiz regrades should still work

Change-Id: I67228b914018fe21358ff08daa1db12988fc43fd
Reviewed-on: https://gerrit.instructure.com/23758
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
QA-Review: Myller de Araujo <myller@instructure.com>
Product-Review: Stanley Stuart <stanley@instructure.com>