debian-mirror-gitlab/spec/models/bulk_imports/batch_tracker_spec.rb

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

17 lines
462 B
Ruby
Raw Normal View History

2023-05-27 22:25:52 +05:30
# frozen_string_literal: true
require 'spec_helper'
RSpec.describe BulkImports::BatchTracker, type: :model, feature_category: :importers do
describe 'associations' do
it { is_expected.to belong_to(:tracker) }
end
describe 'validations' do
subject { build(:bulk_import_batch_tracker) }
it { is_expected.to validate_presence_of(:batch_number) }
it { is_expected.to validate_uniqueness_of(:batch_number).scoped_to(:tracker_id) }
end
end