diff options
author | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2017-03-09 15:04:05 +0100 |
---|---|---|
committer | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2017-03-09 15:10:41 +0100 |
commit | 175a3dfda00fb5a2bf1703803277ee4abb721baf (patch) | |
tree | b6fb9179ad3c6e8ebe20e746dd65f57d4f7a0261 | |
parent | 8a418f3e487cf7d89369ae4ef355c334c89ac6da (diff) | |
download | gitlab-ce-175a3dfda00fb5a2bf1703803277ee4abb721baf.tar.gz |
Fix GitLab QA release inflector strategy
-rw-r--r-- | qa/qa/runtime/release.rb | 2 | ||||
-rw-r--r-- | qa/spec/runtime/release_spec.rb | 6 |
2 files changed, 7 insertions, 1 deletions
diff --git a/qa/qa/runtime/release.rb b/qa/qa/runtime/release.rb index d64b478a41a..e3da00a1881 100644 --- a/qa/qa/runtime/release.rb +++ b/qa/qa/runtime/release.rb @@ -19,7 +19,7 @@ module QA end begin - require "#{version.downcase}/strategy" + require "qa/#{version.downcase}/strategy" rescue LoadError # noop end diff --git a/qa/spec/runtime/release_spec.rb b/qa/spec/runtime/release_spec.rb index 4995ad48ee6..97f0b7e3c89 100644 --- a/qa/spec/runtime/release_spec.rb +++ b/qa/spec/runtime/release_spec.rb @@ -5,6 +5,7 @@ describe QA::Runtime::Release do before do stub_const('QA::CE::Strategy', strategy) + stub_const('QA::EE::Strategy', strategy) end describe '#has_strategy?' do @@ -32,6 +33,11 @@ describe QA::Runtime::Release do context 'when release version does not have extension strategy' do subject { described_class.new('CE') } + before do + hide_const('QA::CE::Strategy') + hide_const('QA::EE::Strategy') + end + describe '#has_strategy?' do it 'returns false' do expect(subject.has_strategy?).to be false |