2019-07-31 22:56:46 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2020-03-13 15:44:24 +05:30
|
|
|
RSpec.shared_examples 'manual playable stage' do |stage_type|
|
2019-07-31 22:56:46 +05:30
|
|
|
let(:stage) { build(stage_type, status: status) }
|
|
|
|
|
|
|
|
describe '#manual_playable?' do
|
|
|
|
subject { stage.manual_playable? }
|
|
|
|
|
|
|
|
context 'when is manual' do
|
|
|
|
let(:status) { 'manual' }
|
|
|
|
|
|
|
|
it { is_expected.to be_truthy }
|
|
|
|
end
|
|
|
|
|
|
|
|
context 'when is scheduled' do
|
|
|
|
let(:status) { 'scheduled' }
|
|
|
|
|
|
|
|
it { is_expected.to be_truthy }
|
|
|
|
end
|
|
|
|
|
|
|
|
context 'when is skipped' do
|
|
|
|
let(:status) { 'skipped' }
|
|
|
|
|
|
|
|
it { is_expected.to be_truthy }
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|