project: update dependencies #366
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: Continuous-Integration | |
on: | |
push: | |
branches: master | |
pull_request: | |
branches: [master, dev] | |
workflow_dispatch: | |
inputs: | |
reason: | |
description: 'Reason' | |
required: false | |
default: 'Manual trigger' | |
jobs: | |
Tests: | |
runs-on: ubuntu-latest | |
# Service containers to run with `container-job` | |
services: | |
# Label used to access the service container | |
redis: | |
# Docker Hub image | |
image: redis | |
# Set health checks to wait until redis has started | |
options: >- | |
--health-cmd "redis-cli ping" | |
--health-interval 10s | |
--health-timeout 5s | |
--health-retries 5 | |
ports: | |
# Maps port 6379 on service container to the host | |
- 6379:6379 | |
strategy: | |
matrix: | |
python-version: [3.7, 3.8, 3.9] | |
requirements-level: [min, pypi] | |
cache-service: [redis] | |
# services: [release, devel] | |
# include: | |
# - services: release | |
# EXTRAS: "all" | |
# REQUIREMENTS: "release" | |
# REQUIREMENTS_LEVEL: "pypi" | |
## - services: lowest | |
## EXTRAS: "all" | |
## REQUIREMENTS: "lowest" | |
## REQUIREMENTS_LEVEL: "min" | |
# - services: devel | |
# EXTRAS: "all" | |
# REQUIREMENTS: "devel" | |
# REQUIREMENTS_LEVEL: "dev" | |
env: | |
CACHE: ${{ matrix.cache-service }} | |
ES_VERSION: ${{matrix.ES_VERSION}} | |
EXTRAS: all #,${{ matrix.EXTRAS }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install Poetry | |
uses: snok/install-poetry@v1 | |
with: | |
version: 1.2.2 | |
- name: Install dependencies | |
run: | | |
docker --version | |
docker-compose --version | |
poetry install | |
- name: Run tests | |
run: | | |
poetry run ./run-tests.sh | |
continue-on-error: false | |
- name: Upload Coverage ${{ matrix.python-version }} | |
if: ${{ matrix.requirements-level == 'pypi' }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
COVERALLS_SERVICE_NAME: github | |
# COVERALLS_FLAG_NAME: test-${{ matrix.services }} | |
# COVERALLS_PARALLEL: true | |
run: | | |
pip install --upgrade coveralls | |
coveralls | |
# coveralls: | |
# needs: [python-tests] | |
# runs-on: ubuntu-latest | |
# steps: | |
# - name: Cancel Previous Runs | |
# uses: styfle/[email protected] | |
# with: | |
# access_token: ${{ github.token }} | |
# | |
# - name: Set up Python 3.6 | |
# uses: actions/setup-python@v2 | |
# with: | |
# python-version: 3.6 | |
# | |
# - name: Finished | |
# env: | |
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
# COVERALLS_PARALLEL_FINISHED: true | |
# run: | | |
# pip install --upgrade coveralls | |
# coveralls --finish |