change ubuntu:24.02 to ubuntu-latest #23
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: GitHub Actions Docker Build and Test | |
on: | |
push: | |
branches: | |
- main # run tests when pushing to the main branch | |
pull_request: | |
branches: | |
- main # run tests when a pull request targets the main branch | |
jobs: | |
docker-test: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Set up Docker | |
uses: docker/setup-buildx-action@v2 | |
- name: Build Docker image | |
run: docker build -t reproducible_dl . | |
- name: Run tests inside Docker container | |
run: docker run --rm -it reproducible_dl pytest |