Skip to content

Commit

Permalink
Merge pull request #16 from golubev/integrate-codecov
Browse files Browse the repository at this point in the history
.github/workflows/pull-request.yaml: add codecov integration
  • Loading branch information
golubev authored Feb 2, 2024
2 parents b9aba2f + d56c8b8 commit b4f2e8d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .env.ci
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
ENVIRONMENT = "test"

SECURITY_SECRET_KEY = "security_secret_key"
SECURITY_ACCESS_TOKEN_EXPIRE_SECONDS = 604800

POSTGRES_HOST = todo_postgres
POSTGRES_DB = test_database
POSTGRES_USER = postgres
Expand All @@ -18,3 +21,6 @@ SMTP_PORT = 1025
SMTP_HOST = todo_mailhog
SMTP_USER =
SMTP_PASSWORD =

FLOWER_USER = todo_user
FLOWER_PASSWORD = "flower_password"
4 changes: 4 additions & 0 deletions .github/workflows/pull-request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,7 @@ jobs:
run: docker compose exec api ./do-lint.sh
- name: Run tests
run: docker compose exec api ./do-test.sh
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
2 changes: 1 addition & 1 deletion application/do-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,4 @@ alembic upgrade head
# insert test data into the database
python tests/seed_database.py

pytest --cov=src --cov-report=term-missing tests "${@}"
pytest --cov=src --cov-report=term-missing --cov-report=xml tests "${@}"

0 comments on commit b4f2e8d

Please sign in to comment.