Skip to content

Commit

Permalink
Add codecov to CI (#4)
Browse files Browse the repository at this point in the history
* add codecov to github action

* Add badge to readme

* fix layout in readme
  • Loading branch information
LukeWeidenwalker authored Nov 30, 2022
1 parent 9f7a958 commit 0aa3cb5
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
7 changes: 6 additions & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,9 @@ jobs:
# run: poetry run mypy

- name: Run pytest
run: poetry run pytest -v
run: poetry run pytest --cov=openeo_processes_dask --cov-report=xml

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
files: ./coverage.xml
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# OpenEO Processes Dask

[![codecov](https://codecov.io/github/Open-EO/openeo-processes-dask/branch/main/graph/badge.svg?token=RA82MUN9RZ)](https://codecov.io/github/Open-EO/openeo-processes-dask)

## Development environment
openeo-processes-dask requires poetry >1.2, see their [docs](https://python-poetry.org/docs/#installation) for installation instructions.

Expand All @@ -25,5 +27,6 @@ poetry run python -m pytest

Note that you can also use the virtual environment that's generated by poetry as the kernel for the ipynb notebooks.

Pre-commit hooks
**Pre-commit hooks**

This repo makes use of [pre-commit](https://pre-commit.com/) hooks to enforce linting & a few sanity checks. In a fresh development setup, install the hooks using `poetry run pre-commit install`. These will then automatically be checked against your changes before making the commit.
7 changes: 6 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ packages = [
{ include = "openeo_processes_dask" }
]


[tool.poetry.dependencies]
python = ">=3.9,<3.10"
geopandas = "^0.12.1"
Expand All @@ -46,6 +45,12 @@ mapclassify = "^2.4.3"
[tool.poetry.group.dev.dependencies]
bokeh = "<3"
pre-commit = "^2.20.0"
pytest-cov = "^4.0.0"

[tool.pytest.ini_options]
testpaths = [
"tests",
]

[build-system]
requires = ["poetry-core>=1.0.0"]
Expand Down

0 comments on commit 0aa3cb5

Please sign in to comment.