Verify we are getting the correct error message from the SubmissionsController
Verify we are getting the correct error message from the SubmissionsController

This test is to verify that the SubmissionsController properly
rejects assignment submissions that have files attached with illegal
file extensions, based on what is whitelisted by the instructor.

Previously the test was not setting the context of the attachment,
which caused the attachment to not be properly associated with the
user.  Because of that, the submission was properly being rejected
but it was being rejected because there was no file attached,
not because of the file extension.  We also weren't checking the
returned error message, so we thought everything was good when it
wasn't.  This patch set fixes those issues.

Fixes CNVS-16135

Test Plan:

None, this patch set only changes a unit test and doesn't actually
touch application code at all.

Change-Id: Ic263a5fd990db1b600e128fbe78134ed21f039a1
Reviewed-on: https://gerrit.instructure.com/42386
Reviewed-by: Simon Williams <088e16a1019277b15d58faf0541e11910eb756f6@instructure.com>
QA-Review: Simon Williams <088e16a1019277b15d58faf0541e11910eb756f6@instructure.com>
QA-Review: Sean Lewis <e0580b9aacf857d9a3792f1965500f217c0fc9c9@instructure.com>
Tested-by: Jenkins <d95b56ce41a2e1ac4cecdd398defd7414407cc08@instructure.com>
Product-Review: Benjamin Porter <fdd60f2e3d506934848b3d0fff79c55f544a2d47@instructure.com>

instructure/canvas-lms,tgroshon/canvas-lms,utkarshx/canvas-lms,Rvor/canvas-lms,SwinburneOnline/canvas-lms,grahamb/canvas-lms,HotChalk/canvas-lms,dgynn/canvas-lms,HotChalk/canvas-lms,va7map/canvas-lms,venturehive/canvas-lms,Rvor/canvas-lms,redconfetti/canvas-lms,snehakachroo1/LSI_replica,redconfetti/canvas-lms,AndranikMarkosyan/lms,efrj/canvas-lms,whalejasmine/canvas-lms,sfu/canvas-lms,leftplusrightllc/canvas-lms,wrdsb/canvas-lms,antoniuslin/canvas-lms,antoniuslin/canvas-lms,matematikk-mooc/canvas-lms,Rvor/canvas-lms,djbender/canvas-lms,sdeleon28/canvas-lms,kyroskoh/canvas-lms,skmezanul/canvas-lms,tgroshon/canvas-lms,narigone/canvas,instructure/canvas-lms,djbender/canvas-lms,roxolan/canvas-lms,instructure/canvas-lms,dgynn/canvas-lms,va7map/canvas-lms,venturehive/canvas-lms,skmezanul/canvas-lms,matematikk-mooc/canvas-lms,roxolan/canvas-lms,Jyaasa/canvas-lms,leftplusrightllc/canvas-lms,greyhwndz/canvas-lms,efrj/canvas-lms,whalejasmine/canvas-lms,narigone/canvas,SwinburneOnline/canvas-lms,sdeleon28/canvas-lms,instructure/canvas-lms,grahamb/canvas-lms,AndranikMarkosyan/lms,sfu/canvas-lms,shidao-fm/canvas-lms,sfu/canvas-lms,fronteerio/canvas-lms,AndranikMarkosyan/lms,shidao-fm/canvas-lms,snehakachroo1/LSI_replica,sfu/canvas-lms,SwinburneOnline/canvas-lms,wrdsb/canvas-lms,HotChalk/canvas-lms,sfu/canvas-lms,Jyaasa/canvas-lms,sfu/canvas-lms,jay3126/canvas-lms,antoniuslin/canvas-lms,juoni/canvas-lms,matematikk-mooc/canvas-lms,gbleydon/canvas-lms,utkarshx/canvas-lms,greyhwndz/canvas-lms,gbleydon/canvas-lms,instructure/canvas-lms,narigone/canvas,samuels410/greatlakes-lms,skmezanul/canvas-lms,va7map/canvas-lms,matematikk-mooc/canvas-lms,grahamb/canvas-lms,sfu/canvas-lms,dgynn/canvas-lms,eCNAP/CANVAS,kyroskoh/canvas-lms,juoni/canvas-lms,gbleydon/canvas-lms,Jyaasa/canvas-lms,shidao-fm/canvas-lms,whalejasmine/canvas-lms,jay3126/canvas-lms,efrj/canvas-lms,utkarshx/canvas-lms,AndranikMarkosyan/lms,samuels410/greatlakes-lms,fronteerio/canvas-lms,SwinburneOnline/canvas-lms,Rvor/canvas-lms,instructure/canvas-lms,instructure/canvas-lms,fronteerio/canvas-lms,greyhwndz/canvas-lms,dgynn/canvas-lms,va7map/canvas-lms,narigone/canvas,leftplusrightllc/canvas-lms,jay3126/canvas-lms,tgroshon/canvas-lms,Jyaasa/canvas-lms,wrdsb/canvas-lms,samuels410/greatlakes-lms,djbender/canvas-lms,snehakachroo1/LSI_replica,kyroskoh/canvas-lms,roxolan/canvas-lms,eCNAP/CANVAS,ShreniiNepal/shrenii_lmp,kyroskoh/canvas-lms,ShreniiNepal/shrenii_lmp,grahamb/canvas-lms,tgroshon/canvas-lms,samuels410/greatlakes-lms,redconfetti/canvas-lms,shidao-fm/canvas-lms,utkarshx/canvas-lms,venturehive/canvas-lms,redconfetti/canvas-lms,venturehive/canvas-lms,juoni/canvas-lms,sdeleon28/canvas-lms,djbender/canvas-lms,greyhwndz/canvas-lms,wrdsb/canvas-lms,roxolan/canvas-lms,ShreniiNepal/shrenii_lmp,eCNAP/CANVAS,sdeleon28/canvas-lms,juoni/canvas-lms,leftplusrightllc/canvas-lms,grahamb/canvas-lms,snehakachroo1/LSI_replica,HotChalk/canvas-lms,eCNAP/CANVAS,skmezanul/canvas-lms,jay3126/canvas-lms,whalejasmine/canvas-lms,efrj/canvas-lms,ShreniiNepal/shrenii_lmp,fronteerio/canvas-lms,antoniuslin/canvas-lms