dpi filter #424
This file contains 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: C/I testing with coverage | |
on: [push, pull_request] | |
jobs: | |
build: | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install Python dependencies | |
run: | | |
sudo apt-get update && sudo apt-get install --no-install-recommends --yes --quiet python3-pip python3-setuptools python3-wheel libpython3-dev python3-venv | |
- name: Install system dependencies | |
run: | | |
sudo apt-get update && sudo apt-get install --no-install-recommends --yes --quiet gcc-7 gcc gdal-bin imagemagick ffmpeg libmediainfo0v5 exiftool libjpeg-progs libexempi8 | |
sudo gcc -o /usr/bin/dcraw -O4 external/dcraw.c -lm -DNODEPS | |
- name: Install dependencies for sqlite GIS | |
run: | | |
sudo apt-get update && sudo apt-get install libspatialite7 libsqlite3-mod-spatialite spatialite-bin | |
- name: Install Python packages | |
run: | | |
python3 -m pip install --upgrade pip | |
python3 -m venv venv | |
. venv/bin/activate | |
pip3 install wheel | |
pip3 install -r SpiMediaGallery/requirements.txt | |
- name: Installs Python packages and runs test | |
env: | |
FORCE_SQLITE3_DATABASE: 1 | |
run: | | |
. venv/bin/activate | |
cp utils/spi_media_gallery_buckets.json "$HOME/.spi_media_gallery_buckets.json" | |
rm -rf SpiMediaGallery/main/migrations/* | |
source tools/environment-variables-for-test.sh | |
cd SpiMediaGallery | |
coverage run manage.py test | |
coverage xml | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v1 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
flags: unittests | |
name: codecov-project | |
fail_ci_if_error: false |