blob: 34c83c420565dcd950193dbbff175b7aa3542f5b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
# frozen_string_literal: true
require 'spec_helper'
RSpec.describe Gitlab::Database::Migrations::BaseBackgroundRunner, :freeze_time do
let(:result_dir) { Dir.mktmpdir }
after do
FileUtils.rm_rf(result_dir)
end
context 'subclassing' do
subject { described_class.new(result_dir: result_dir) }
it 'requires that jobs_by_migration_name be implemented' do
expect { subject.jobs_by_migration_name }.to raise_error(NotImplementedError)
end
it 'requires that run_job be implemented' do
expect { subject.run_job(nil) }.to raise_error(NotImplementedError)
end
end
end
|