fix flaky CreateOutcomeProficiency mutation specs

fixes DE-254
flag = none

Test Plan:
 - tests pass 100%

Change-Id: Ic74ad73f09c1344b4cffa9223298e5fe33065e61
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/247330
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Aaron Ogata <aogata@instructure.com>
QA-Review: Ryan Norton <rnorton@instructure.com>
Product-Review: Ryan Norton <rnorton@instructure.com>
This commit is contained in:
Ryan Norton 2020-09-10 11:16:03 -06:00
parent f856ed0524
commit b6cf84025a
1 changed files with 7 additions and 0 deletions

View File

@ -27,6 +27,13 @@ describe Mutations::CreateOutcomeProficiency do
@teacher = @course.enroll_teacher(User.create!, enrollment_state: 'active').user
end
let(:audit_log_field_extension) { class_double(AuditLogFieldExtension).as_stubbed_const }
before(:each) do
# prevent unnecessary calls to dynamo (audit logs)
allow(audit_log_field_extension).to receive(:enabled?).and_return false
end
def execute_with_input(create_input, user_executing: @admin)
mutation_command = <<~GQL
mutation {