This commit is contained in:
parent
5888e281ea
commit
3a305996ed
1 changed files with 16 additions and 7 deletions
|
@ -7,16 +7,25 @@ on:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
test:
|
||||||
needs: build
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
|
||||||
image: ${{ vars.CONTAINER_REGISTRY }}/${{ vars.CONTAINER_IMAGE_NAME }}:latest
|
|
||||||
options: --entrypoint ""
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Run Django tests
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v3
|
||||||
|
|
||||||
|
- name: Build Docker image (local only)
|
||||||
|
uses: docker/build-push-action@v5
|
||||||
|
with:
|
||||||
|
context: .
|
||||||
|
push: false
|
||||||
|
tags: website:test
|
||||||
|
|
||||||
|
- name: Run Django tests in container
|
||||||
run: |
|
run: |
|
||||||
python -m hub migrate --noinput
|
docker run --rm \
|
||||||
python -m hub test --verbosity=2
|
-v $(pwd):/app \
|
||||||
|
-w /app \
|
||||||
|
website:test \
|
||||||
|
sh -c 'python -m hub migrate --noinput && python -m hub test --verbosity=2'
|
Loading…
Add table
Add a link
Reference in a new issue