You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
976 B
23 lines
976 B
# Development
|
|
|
|
## Setup
|
|
Clone the repo locally, and create a Python virtual env (recommend using [pew](https://github.com/berdario/pew)):
|
|
```bash
|
|
pew new config-spec
|
|
```
|
|
|
|
Inside the repo (beside `setup.py`) and inside the virtual env, install as an editable python package, using the `dev` extras with:
|
|
```bash
|
|
pip install -e ./[dev]
|
|
```
|
|
|
|
## Testing
|
|
### During development
|
|
Run `pytest` within venv to run test suite and flake8 (linting+style) checks.
|
|
|
|
To get a coverage report, run `pytest --cov configspec`. Run `coverage html` afterward or `pytest --cov configspec --cov-report html` to generate a html report with line-specific coverage data.
|
|
|
|
Assuming `pew` was used for the venv, running `pew wipeenv` will uninstall all packages to allow the pip install to be run from scratch.
|
|
|
|
### Before release
|
|
Run `tox` within venv to check the tests for all supported python versions, and check package installation all works. Use `tox -r` to force recreation of every environment. |