Add a test for deletion of importing_or_inactive?

This commit is contained in:
Shinya Maeda 2017-05-26 21:41:32 +09:00
parent 62ecce78ed
commit ef61829b58
1 changed files with 8 additions and 0 deletions

View File

@ -25,6 +25,14 @@ describe Ci::PipelineSchedule, models: true do
expect(pipeline_schedule).not_to be_valid
end
context 'when active is false' do
it 'does not allow nullified ref' do
pipeline_schedule = build(:ci_pipeline_schedule, :inactive, ref: nil)
expect(pipeline_schedule).not_to be_valid
end
end
end
describe '#set_next_run_at' do