Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.github: rebuild ginkgo tests in case of cache miss #27158

Merged
merged 1 commit into from
Jul 31, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
36 changes: 36 additions & 0 deletions .github/workflows/conformance-runtime.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ jobs:
- name: Set Environment Variables
uses: ./.github/actions/set-env-variables

# If any of these steps are modified, please update the copy of these
# steps further down under the 'setup-and-test' jobs.

# Load Ginkgo build from GitHub
- name: Load ginkgo runtime from GH cache
uses: actions/cache@88522ab9f39a2ea568f7027eddc7d8d8bc9d59c8 # v3.3.1
Expand Down Expand Up @@ -250,6 +253,39 @@ jobs:
path: /tmp/.ginkgo-build/
key: ${{ runner.os }}-ginkgo-runtime-${{ hashFiles('**/*.go') }}

- name: Install Go
if: ${{ steps.cache.outputs.cache-hit != 'true' }}
uses: actions/setup-go@fac708d6674e30b6ba41289acaab6d4b75aa0753 # v4.0.1
with:
# renovate: datasource=golang-version depName=go
go-version: 1.20.6

- name: Build Ginkgo
if: ${{ steps.cache.outputs.cache-hit != 'true' }}
shell: bash
run: |
go install github.com/onsi/ginkgo/ginkgo@v1.16.5
mkdir -p /tmp/.ginkgo-build

- name: Build Test
if: ${{ steps.cache.outputs.cache-hit != 'true' }}
shell: bash
run: |
cd test
/home/runner/go/bin/ginkgo build
strip test.test
tar -cz test.test -f test.tgz

- name: Store Ginkgo Test in GitHub cache path
if: ${{ steps.cache.outputs.cache-hit != 'true' }}
shell: bash
run: |
mkdir -p /tmp/.ginkgo-build/
if [ -f test/test.tgz ]; then
cp test/test.tgz /tmp/.ginkgo-build/
echo "file copied"
fi

- name: Copy Ginkgo binary
shell: bash
run: |
Expand Down