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

pytest-api test: fix ping server step #997

Merged
Merged
Changes from 1 commit
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
Next Next commit
Compact docker.yml workflow
  • Loading branch information
odulcy-mindee committed Jul 26, 2022
commit 6d21ad644ebc6f648bfd6e5ff68039b3d96530b3
12 changes: 7 additions & 5 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,17 @@ jobs:

pytest-api:
runs-on: ubuntu-latest
env:
PORT=8002
steps:
- uses: actions/checkout@v2
- name: Build & run docker
run: PORT=8002 docker-compose up -d --build
run: docker-compose up -d --build
- name: Ping server
run: curl http://localhost:8002/docs
run: curl http://localhost:$PORT/docs
- name: Install dependencies in docker
run: |
PORT=8002 docker-compose exec -T web python -m pip install --upgrade pip
PORT=8002 docker-compose exec -T web pip install -r requirements-dev.txt
docker-compose exec -T web python -m pip install --upgrade pip
docker-compose exec -T web pip install -r requirements-dev.txt
- name: Run docker test
run: PORT=8002 docker-compose exec -T web pytest .
run: docker-compose exec -T web pytest .