From 6e86b30cc10a17c4707ad7ad757380f0ba3f14c9 Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Tue, 23 Aug 2022 14:41:46 +0900 Subject: [PATCH] Use openstack_spec_helper from zuul checkout Change-Id: I9b8c3210a1e69592872a57daeeb74c5d7e67bf2a Co-Authored-By: Tobias Urdin (cherry picked from commit 6212bb5ea8ee4235f984fae6a1ee4d4b0ac5756c) (cherry picked from commit 4935899e9fc49950bc5df5cf4ddc3723ce8f23f3) --- Gemfile | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/Gemfile b/Gemfile index 8c7a257b..3f465614 100644 --- a/Gemfile +++ b/Gemfile @@ -1,14 +1,23 @@ source ENV['GEM_SOURCE'] || "https://rubygems.org" group :development, :test, :system_tests do - if ENV['ZUUL_PROJECT'] == 'openstack/puppet-openstack_spec_helper' - gem 'puppet-openstack_spec_helper', - :path => '../..', + spec_helper_dir = '/home/zuul/src/opendev.org/openstack/puppet-openstack_spec_helper' + if File.directory?(spec_helper_dir) + if ENV['ZUUL_PROJECT'] == 'openstack/puppet-openstack_spec_helper' + gem 'puppet-openstack_spec_helper', + :path => '../..', :require => 'false' + else + gem 'puppet-openstack_spec_helper', + :path => spec_helper_dir, + :require => 'false' + end else + spec_helper_version = ENV['ZUUL_BRANCH'] || "master" gem 'puppet-openstack_spec_helper', - :git => 'https://opendev.org/openstack/puppet-openstack_spec_helper', - :require => 'false' + :git => 'https://opendev.org/openstack/puppet-openstack_spec_helper', + :ref => spec_helper_version, + :require => 'false' end end