4ec16912b8
- rewords examples starting with 'should' - rewords examples starting with 'it' Note: I had to manually fixup "onlies" to "only"
23 lines
582 B
Ruby
23 lines
582 B
Ruby
require 'spec_helper'
|
|
|
|
describe Forever do
|
|
describe '.date' do
|
|
subject { described_class.date }
|
|
|
|
context 'when using PostgreSQL' do
|
|
it 'returns Postgresql future date' do
|
|
allow(Gitlab::Database).to receive(:postgresql?).and_return(true)
|
|
|
|
expect(subject).to eq(described_class::POSTGRESQL_DATE)
|
|
end
|
|
end
|
|
|
|
context 'when using MySQL' do
|
|
it 'returns MySQL future date' do
|
|
allow(Gitlab::Database).to receive(:postgresql?).and_return(false)
|
|
|
|
expect(subject).to eq(described_class::MYSQL_DATE)
|
|
end
|
|
end
|
|
end
|
|
end
|