Skip to content

Commit

Permalink
Reference git hash in the version during integration testing
Browse files Browse the repository at this point in the history
Signed-off-by: Martin Styk <[email protected]>
  • Loading branch information
StykMartin committed Dec 24, 2023
1 parent ddfb50a commit 1308016
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/review-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,13 @@ jobs:
mysql -uroot -p${{ env.MYSQL_ROOT_PASSWORD }} -h database < init.sql
sed -i 's/@localhost/@database/g' IntegrationTests/server-test.cfg
- name: Update version
run: |
# Update the version in common/__init__.py, as this file is used in the application and tests to determine the version
current_version=$(grep -oE "__version__ = '[^']+'" Common/bkr/common/__init__.py | cut -d "'" -f 2)
new_version="$current_version.git.$(git rev-parse --short HEAD)"
sed -i "s/__version__ = '$current_version'/__version__ = '$new_version'/" Common/bkr/common/__init__.py
- name: Run integration tests for ${{ matrix.test-target }}
run: |
pushd IntegrationTests
Expand Down

0 comments on commit 1308016

Please sign in to comment.