debian-mirror-gitlab/spec/models/ci/pipeline_metadata_spec.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

15 lines
419 B
Ruby
Raw Normal View History

2022-11-25 23:54:43 +05:30
# frozen_string_literal: true
require 'spec_helper'
RSpec.describe Ci::PipelineMetadata do
it { is_expected.to belong_to(:project) }
it { is_expected.to belong_to(:pipeline) }
describe 'validations' do
2023-01-13 00:05:48 +05:30
it { is_expected.to validate_length_of(:name).is_at_least(1).is_at_most(255) }
2022-11-25 23:54:43 +05:30
it { is_expected.to validate_presence_of(:project) }
it { is_expected.to validate_presence_of(:pipeline) }
end
end