spec: Run live events specs if an env var is set

All are being skipped for now due to flakiness, but we'll want to
be able to run them in a separate job.

Change-Id: I2389d826a4161bee4a3678a67f8fbd1596a5f521
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/252314
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Weston Dransfield <wdransfield@instructure.com>
QA-Review: Tucker Mcknight <tmcknight@instructure.com>
Product-Review: Tucker Mcknight <tmcknight@instructure.com>
This commit is contained in:
Tucker McKnight 2020-11-09 16:44:51 -07:00 committed by Tucker Mcknight
parent 0fc8ce19f7
commit cb83a398dd
14 changed files with 17 additions and 13 deletions

View File

@ -29,7 +29,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
course_model

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (8/18/2020)"
skip "INTEROP-6100 (8/18/2020)" unless run_live_events_specs?
live_event.emit_with do
course_factory

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (8/18/2020)"
skip "INTEROP-6100 (8/18/2020)" unless run_live_events_specs?
live_event.emit_with do
course = course_factory

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
# Our contract tests only capture the latest live event that's emitted,

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
opts = { context: course_model }

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
opts = { context: course_model }

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
opts = { context: course_model }

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
opts = { context: course_model }

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
outcome = outcome_model

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
params = {

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
# arrange

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
params = {

View File

@ -31,7 +31,7 @@ RSpec.describe 'Canvas LMS Live Events', :pact_live_events do
end
it 'keeps the contract' do
skip "INTEROP-6100 (11/5/2020)"
skip "INTEROP-6100 (11/5/2020)" unless run_live_events_specs?
live_event.emit_with do
# arrange

View File

@ -905,3 +905,7 @@ end
def enable_default_developer_key!
enable_developer_key_account_binding!(DeveloperKey.default)
end
def run_live_events_specs?
ENV.fetch('RUN_LIVE_EVENTS_SPECS', '0') == '1'
end