Skip to content

Commit

Permalink
improve docs
Browse files Browse the repository at this point in the history
  • Loading branch information
JakNowy committed Jun 28, 2024
1 parent 51fddc1 commit a4833d3
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
16 changes: 15 additions & 1 deletion backend/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,22 @@ Nevertheless, if it doesn't detect a change but a syntax error, it will just sto
To test the backend run:

```console
$ bash ./scripts/test.sh
$ bash ./scripts/start-test.sh
```
...or inside docker:
```console
$ docker compose exec backend bash ./tests-start.sh
```

To run a specific test:
```console
$ bash ./tests-start.sh app/tests/api/routes/test_users.py::test_update_user
```
To run a specific test without coverage:
```console
$ bash ./tests-start.sh --no-coverage app/tests/api/routes/test_users.py::test_update_user
```


The tests run with Pytest, modify and add tests to `./backend/app/tests/`.

Expand Down
2 changes: 1 addition & 1 deletion backend/scripts/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ if [ $NO_COVERAGE -eq 0 ]; then
coverage html --title "Coverage Report"
else
pytest "$@"
fi
fi

0 comments on commit a4833d3

Please sign in to comment.