summaryrefslogtreecommitdiff
path: root/spec/models/internal_id_spec.rb
diff options
context:
space:
mode:
authorJan Provaznik <jprovaznik@gitlab.com>2019-06-26 14:33:57 +0000
committerStan Hu <stanhu@gmail.com>2019-06-26 14:33:57 +0000
commit813b8aad24a88aa014c75487fe2856fa385d4cf6 (patch)
tree9cc524b1cfa0062f1944236bcb66c7d9fec5512d /spec/models/internal_id_spec.rb
parent05a7fcbdf79fbff25048161657cfacdd58395b76 (diff)
downloadgitlab-ce-813b8aad24a88aa014c75487fe2856fa385d4cf6.tar.gz
Fix failing spec/models/internal_id_spec.rb spec
The spec is too strict about how many `current_version` should be called - if the spec is called separately, it's called 3 times, if all specs run it's called twice. This is similar to the change done in 9b752791624ce618810b9d65251582e56c37dee7
Diffstat (limited to 'spec/models/internal_id_spec.rb')
-rw-r--r--spec/models/internal_id_spec.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/models/internal_id_spec.rb b/spec/models/internal_id_spec.rb
index 806b4f61bd8..28630f7d3fe 100644
--- a/spec/models/internal_id_spec.rb
+++ b/spec/models/internal_id_spec.rb
@@ -158,7 +158,7 @@ describe InternalId do
before do
described_class.reset_column_information
# Project factory will also call the current_version
- expect(ActiveRecord::Migrator).to receive(:current_version).twice.and_return(InternalId::REQUIRED_SCHEMA_VERSION - 1)
+ expect(ActiveRecord::Migrator).to receive(:current_version).at_least(:once).and_return(InternalId::REQUIRED_SCHEMA_VERSION - 1)
end
it 'does not reset any of the iids' do