leave context host for attachment_json in reports

attachment_json will do this for you.
this prevents double  context information from the
merge of options in attachment_json

refs CNVS-10842

test plan
 - run report with canvas on port 3000
 - report object response should have the correct
   attachment download url

Change-Id: I58caffede266dee157afab63fd82a0a4a4bd5213
Reviewed-on: https://gerrit.instructure.com/40638
QA-Review: Dave Jungst <dave@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Rob Orton <rob@instructure.com>
respect locale preferences on new user account confirmation failure page

fixes CAT-464

Test Plan
  1. Fire up canvas with full i18n support configured
     (i.e. $ RAILS_LOAD_ALL_LOCALES=true rails server)
  2. Submit a POST request to the canvas api to create a new user
     (i.e. '/accounts/:id/users') with request headers [:user][:locale]
     set to a supported canvas locale (i.e. 'zh')
  3. Navigate to the new user account confirmation page from the email
     link, set a password and submit the form
  4. With your new user still signed in, navigate back to the confirm URL
     and ensure the page is still localized
  5. Logout from canvas and navigate back to the confirm URL again and
     ensure the page is still localized

Change-Id: I47127098f88b53d9b66b2a739cc4fd8836f14523
Reviewed-on: https://gerrit.instructure.com/39661
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ethan Gunderson <egunderson@instructure.com>
Reviewed-by: Nick Houle <nhoule@instructure.com>
Product-Review: Dave Donahue <ddonahue@instructure.com>
QA-Review: Dave Donahue <ddonahue@instructure.com>
Converts wiki page title to use h1 rather than h2

fixes CNVS-14906

Test Plan:
  1. Navigate to a page under Pages in a course
  2. In VO, press ctrl+option+cmd+h to go to the first and
     only header
  3. Press a second time to confirm that there are no more
     headers
  4. Hold shift while pressing those same keys to confirm that
     there are no previous headers
  5. Header should be recognized as a H1

Change-Id: I29ee832829581f08e23f0d3b01a264e908c67deb
Reviewed-on: https://gerrit.instructure.com/40673
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Shaw <ryan@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
Product-Review: Cosme Salazar <cosme@instructure.com>
add lti launch params and substitutions

test plan:
  - create a tool with ContentItemSelectionResponse
  - it should send the parameter 'tool_consumer_instance_contact_email'
  - it should substitute the parameter $Canvas.user.prefersHighContrast

fixes PLAT-622

Change-Id: If55d0a1b488f82a90c8aa620fd037f7e7c7b0272
Reviewed-on: https://gerrit.instructure.com/40703
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Nathan Mills <nathanm@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
Color Variables for Canvas UI

fixes CNVS-15117

These introduce color variables for Canvas! With these
fancy variables we can now start getting color consistency through
Canvas! Huzzah!

UI Testing:

- Compile sass
- Compile styleguide (bundle exec rake css:styleguide)
- There are two separate styleshees: one for legacy, one for new;
these are being hidden or shown based on css
- See QA procedure below for expected testing results

QA Testing:

- With the new_styles tag off, in /styleguide you should see a
"Canvas Colors - Legacy" section with Base Colors & High Contrast
- Width new_styles flag on, in /stylguide you should see a
"Canvas Colors - New" section with Base Colors & High Contrast
- You should never see two Canvas Color sections at a time

Change-Id: I2536ce5bf49bc0de2166cdcd8f3be15be9ff6625
Reviewed-on: https://gerrit.instructure.com/40309
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Matt Fairbourn <mfairbourn@instructure.com>
Product-Review: Colleen Palmer <colleen@instructure.com>
Reviewed-by: Chris Hart <chart@instructure.com>
No more textures in Canvas

fixes CNVS-15254
fixes CNVS-14958

This takes out the big textured backgrounds we have in Canvas and
makes everything flat. I've attached screenshots to the story to
see what all is being changed. This affects the following areas:

- Main global header
- Main sidebar left nav
- Body background

This also takes off some annoying drop-shadows we had on the user
navigation (top right) and the global Courses drop-down box.

Yay for a cleaner looking Canvas!

Testing:

- Load up Canvas, make sure the color changes appear for you and
match the screenshots

Change-Id: I3557e66d7d91c3999ad67bfa92202e61c7da44cb
Reviewed-on: https://gerrit.instructure.com/40527
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Colleen Palmer <colleen@instructure.com>
QA-Review: Anna Koalenz <akoalenz@instructure.com>
Reviewed-by: Derek DeVries <ddevries@instructure.com>
Reviewed-by: Chris Hart <chart@instructure.com>
send user id for ContentItemSelectionResponse launches

test plan:
 - Install a tool with a message type ContentItemSelectionResponse
 - it should contain a opaque user_id

Change-Id: Ic2f6585adfe2d9792f974d1d58db2b82da2cdff2
Reviewed-on: https://gerrit.instructure.com/40718
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
initialize rack-mini-profiler for rails3

fixes: CNVS-15198

Test Plan:

  - Make sure you have Application Profiling permission.
  - Add ?pp=enable to the end of the url.
  - A profiler output will apear in the top left corner of the screen
    showing that it ran for the request.
  - Add ?pp=disable to the end of the url.
  - The profiler output button should be gone.

Change-Id: I6fa2dee3affa388d07c6eccf05c26c0747ddcd79
Reviewed-on: https://gerrit.instructure.com/40312
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Brian Palmer <brianp@instructure.com>
QA-Review: August Thornton <august@instructure.com>
Product-Review: Nick Cloward <ncloward@instructure.com>
DA - notifications for assignments

fixes CNVS-13933

test plan (with a course setup for DA):

for the following tests:
* perform them on assignments that are only_visible_to_overrides
* _and_ again on assignments that should be visible to everyone (regression)

- mute an existing assignment that has a due date for one section only
- unmute it
- verify that the *unmuted* notification only go to the students & admins who can see the assignment

notes: must be an existing assignment that is more than 30 minutes old

Change-Id: Ic26fe29a8b1db06e376fdeae129636b0a097fab1
Reviewed-on: https://gerrit.instructure.com/37271
Reviewed-by: Cameron Sutter <csutter@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Amber Taniuchi <amber@instructure.com>
Product-Review: Liz Abinante <labinante@instructure.com>
require course assignment groups in a saner way

fixes CNVS-15252

test plan:
- create a new course and DO NOT visit the assignment index page
- go create a new ungraded discussion
- refresh the discussion show page a few times
- go to the assignment index page
- there should only be 1 assignment group (the default)
- repeat the process with an ungraded quiz

Change-Id: If6714bef05379a0f1253a0843d473695a1372456
Reviewed-on: https://gerrit.instructure.com/40709
Reviewed-by: Mike Nomitch <mnomitch@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Amber Taniuchi <amber@instructure.com>
Product-Review: Simon Williams <simon@instructure.com>
Show full timestamps on conversation messages

Fixes CNVS-13871

Test plan:
  - Create and send a conversation message
  - Locate the message under "Sent" and click on it
  - Ensure that the the full date and time, including the year, are
    displayed in the upper-right corner of the message

Change-Id: I00c3c0df252dc8e32e4aeb2567460c7507750dda
Reviewed-on: https://gerrit.instructure.com/40675
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Janelle Seegmiller <jseegmiller@instructure.com>
Reviewed-by: Matthew Wheeler <mwheeler@instructure.com>
QA-Review: Steven Shepherd <sshepherd@instructure.com>
Reviewed-by: Mark Severson <markse@instructure.com>
use ruby 2.1 compatible mocha with all versions of ruby

makes the lockfile the same between 1.9 and 2.1

Change-Id: I3ab1c3c7a7fcb8e6a5aba0170744d04739029209
Reviewed-on: https://gerrit.instructure.com/40753
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 double requiring of application.rb

This happens when script/rails is executed via a symlinked canvas
directory

Change-Id: I64fc408244ead13c3c78580c3b3e72102445df34
Reviewed-on: https://gerrit.instructure.com/40740
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Cody Cutrer <cody@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
Updated es translation

Change-Id: Ic8301c484cb63827abd5e368766e4ad46f40621c
Updated de translation

Change-Id: I22cbbf7c6fee0bca7dba3f6584da8149ec4a2e1c
Updated ru translation

Change-Id: I1fa3916dec52d8e2e95c0580638e5c3c7b9a1047
Updated fr translation

Change-Id: I02c67a56dd50c880e4813f6df7ee31fea00845ae
Updated pl translation

Change-Id: I7c8aa3ba1aa8510493da1d84a3e75711ff6c3fb8
Updated zh translation

Change-Id: Ifc0e4ba6a86edc1a293a506949c0eeb29ff900ff
Updated ar translation

Change-Id: Iae6b8ffb7d7238e84485c77b5afae0d5f6d9ef0a