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

Run tests on PR as well #70

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -137,16 +137,14 @@ jobs:
name: ${{ steps.image-variables.outputs.tag }}
path: ${{ steps.metadata.outputs.bake-file }}
- name: Run tests
# buildx does not support outputting the image so we need to pull it and run tests
if: needs.version.outputs.push == 'true'
run: |
docker images
# Test the pixi binary is available
docker run --rm ghcr.io/prefix-dev/pixi:${{ needs.version.outputs.new-version }}-${{ steps.image-variables.outputs.tag }} pixi --version
docker run --rm ${{ steps.build.outputs.digest }} pixi --version
# Test end-to-end pixi workflow
docker run --rm ghcr.io/prefix-dev/pixi:${{ needs.version.outputs.new-version }}-${{ steps.image-variables.outputs.tag }} sh -c "mkdir /app && cd /app && pixi init && pixi add python && pixi run python --version"
docker run --rm ${{ steps.build.outputs.digest }} sh -c "mkdir /app && cd /app && pixi init && pixi add python && pixi run python --version"
# Test pixi global binaries are in PATH
docker run --rm ghcr.io/prefix-dev/pixi:${{ needs.version.outputs.new-version }}-${{ steps.image-variables.outputs.tag }} sh -c "pixi global install rsync && rsync --version"
docker run --rm ${{ steps.build.outputs.digest }} sh -c "pixi global install rsync && rsync --version"
- name: Image digest
run: echo ${{ steps.build.outputs.digest }}

Expand Down
Loading