Skip to content

Commit

Permalink
Use versioned build repo for E2E tests (Release 2.0) (#1623)
Browse files Browse the repository at this point in the history
* Use versioned build repo for E2E tests (Release 2.0)
Release 2.0 for #1556

* Avoid hardcoded value, pull E2E build repo version from existing information
  • Loading branch information
treydock authored Nov 29, 2021
1 parent 299c062 commit 70e2735
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -104,3 +104,4 @@ jobs:
run: bundle exec rake test:e2e
env:
BEAKER_set: ${{ matrix.dist }}
OOD_BUILD_REPO: ${{ matrix.version }}
5 changes: 5 additions & 0 deletions spec/e2e/e2e_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,15 @@ def ondemand_repo
end
end

def build_repo_version
ENV['OOD_BUILD_REPO'] || '2.0'
end

def install_ondemand
if host_inventory['platform'] == 'redhat'
release_rpm = 'https://yum.osc.edu/ondemand/latest/ondemand-release-web-latest-1-6.noarch.rpm'
on hosts, "[ -f /etc/yum.repos.d/ondemand-web.repo ] || #{packager} install -y #{release_rpm}"
on hosts, "sed -i 's|/latest/|/build/#{build_repo_version}/|g' /etc/yum.repos.d/ondemand-web.repo"
config_manager = if host_inventory['platform_version'] =~ /^7/
'yum-config-manager'
else
Expand Down

0 comments on commit 70e2735

Please sign in to comment.