Add enhydris_api_client.put_timeseries() (fixes DEV-130) #63
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Tests | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| branches: | |
| - master | |
| jobs: | |
| test: | |
| runs-on: ubuntu-24.04 | |
| strategy: | |
| matrix: | |
| include: | |
| - python-version: "3.10" | |
| include-codecov: false | |
| - python-version: "3.11" | |
| include-codecov: false | |
| - python-version: "3.12" | |
| include-codecov: false | |
| - python-version: "3.13" | |
| include-codecov: true | |
| steps: | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Create and activate venv | |
| run: | | |
| python -m venv ~/.venv | |
| source ~/.venv/bin/activate | |
| pip install -U pip 'setuptools>=61' | |
| - uses: actions/checkout@v3 | |
| - name: Install Dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y gdal-bin libgdal-dev postgresql-16-postgis-3 | |
| source ~/.venv/bin/activate | |
| # numpy<2 is needed for gdal to contain support for gdal array | |
| pip install 'numpy<2' | |
| CPLUS_INCLUDE_PATH=/usr/include/gdal C_INCLUDE_PATH=/usr/include/gdal pip install --no-build-isolation 'gdal==3.8.4' | |
| pip install coverage isort flake8 'black<25' twine setuptools build pyright setuptools_scm cython | |
| pip install -e . | |
| - name: Run Tests | |
| run: | | |
| source ~/.venv/bin/activate | |
| black --check . | |
| flake8 --extend-ignore=E501 . | |
| isort --check-only --diff --profile=black *.py . | |
| pyright . | |
| python -m build | |
| twine check dist/* | |
| coverage run --include="./*" --omit="docs/","*/tests/*","_version.py","*.pyx" -m unittest -v | |
| coverage json | |
| - name: Upload coverage to Codecov | |
| if: matrix.include-codecov == true | |
| uses: codecov/codecov-action@v4 | |
| with: | |
| token: ${{ secrets.CODECOV_TOKEN }} |