don't check quota for quiz file upload questions
test plan: * try to upload a file greater than 50MB for a quiz file upload question submission * it should be successful closes #CNVS-27148 Change-Id: Id92ac58a31d0ab38b311fc5227dbd139bb1e35ad Reviewed-on: https://gerrit.instructure.com/73050 Tested-by: Jenkins Reviewed-by: Jeremy Stanley <jeremy@instructure.com> QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com> Product-Review: James Williams <jamesw@instructure.com>
This commit is contained in:
parent
f65a9919b6
commit
543e13286b
|
@ -64,8 +64,7 @@ class Quizzes::QuizSubmissionFilesController < ApplicationController
|
|||
raise ActiveRecord::RecordNotFound unless quiz_submission
|
||||
|
||||
if authorized_action(quiz, @current_user, :submit)
|
||||
json = api_attachment_preflight_json quiz_submission, request,
|
||||
:check_quota => true, :file_param => 'file'
|
||||
json = api_attachment_preflight_json quiz_submission, request, :file_param => 'file'
|
||||
|
||||
render :json => json
|
||||
end
|
||||
|
|
|
@ -49,7 +49,7 @@ describe Quizzes::QuizSubmissionFilesController, type: :request do
|
|||
end
|
||||
|
||||
def has_query_exemption?
|
||||
false
|
||||
true
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -584,6 +584,9 @@ describe "quizzes" do
|
|||
q.generate_quiz_data
|
||||
q.save!
|
||||
_filename, @fullpath, _data = get_file "testfile1.txt"
|
||||
|
||||
Setting.set('context_default_quota', '1') # shouldn't check quota
|
||||
|
||||
user_session(@student)
|
||||
get "/courses/#{@course.id}/quizzes/#{q.id}/take"
|
||||
expect_new_page_load do
|
||||
|
|
Loading…
Reference in New Issue