You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
4.``poetry run pytest -rA tests/simulation`` - run V2 related tests
67
-
5.``poetry run pytest -rA --ignore tests/simulation`` - run V1 related tests (cannot be run altogether)
68
-
6.``pytest -rA tests/simulation --cov-report=html --cov=flow360/component/simulation`` - see test coverage report for V2 client
69
-
7.``pytest -rA --ignore tests/simulation --cov-report=html --cov=flow360 && open htmlcov/index.html`` - see test coverage report for V1+V2 client
62
+
## pre-commit hooks
63
+
64
+
This project uses [autohooks](https://github.com/greenbone/autohooks) to run formatting and linting checks automatically before each commit. To activate:
65
+
66
+
```bash
67
+
poetry run autohooks activate
68
+
```
69
+
70
+
This installs a git pre-commit hook that runs:
71
+
-**black** — auto-formatting
72
+
-**isort** — import sorting
73
+
-**pylint** — code style checking
74
+
-**sort_json** — sorts keys in `tests/**/*.json` reference files for clean diffs
75
+
76
+
The hooks only process staged files, so they are fast. If you skip activation, CI will still catch issues.
77
+
78
+
## check in (manual)
79
+
1.``black .`` — auto-formatting
80
+
2.``isort .`` — sorts imports
81
+
3.``python tools/sort_ref_json.py`` — sorts keys in test reference JSON files
0 commit comments