Files
pepperplus-cb/README.md
Kasper 2069ac1a93 feat: automatic testing
This commit adds a .gitlab-ci.yml file, which is responsible for
defining jobs to be run (in this case only running the test suite)

ref: N25B-65
2025-10-22 14:05:45 +02:00

45 lines
1.1 KiB
Markdown

## Development environment
We begin by installing UV (very nice utility for managing packages and Python version):
```bash
# On MacOS and Linux.
curl -LsSf https://astral.sh/uv/install.sh | sh
```
```bash
# On Windows.
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
```
Using UV, installing the packages and virtual environment is as simple as typing the following (inside the root directory of this repository):
```bash
uv sync
```
## Running
To run the project (development server), execute the following command (while inside the root repository):
```bash
uv run fastapi dev src/control_backend/main.py
```
## Testing
Testing happens automatically when opening a merge request to any branch. If you want to manually run the test suite, you can do so by running the following:
```bash
uv run --only-group test pytest
```
## GitHooks
To activate automatic commits/branch name checks run:
```shell
git config --local core.hooksPath .githooks
```
If your commit fails its either:
branch name != <type>/description-of-branch ,
commit name != <type>: description of the commit.
<ref>: N25B-Num's