Skip to content

Merge pull request #13 from Spiderpig86/dependabot/pip/certifi-2022.12.7 #25

Merge pull request #13 from Spiderpig86/dependabot/pip/certifi-2022.12.7

Merge pull request #13 from Spiderpig86/dependabot/pip/certifi-2022.12.7 #25

Workflow file for this run

name: CI
on:
push:
branches:
- master
- feature/*
- hotfix/*
pull_request:
branches:
- master
jobs:
build:
strategy:
matrix:
python_version:
- 3.7
- 3.8
os:
- ubuntu
name: build (${{ matrix.os }}/python-${{ matrix.python_version }})
runs-on: ${{ matrix.os }}-latest
env:
CODECOV_TOKEN: 'R8j3dn7hMp45rFO/PbP+5FOob4wo9nONhb07kVcvoasRTWiVIHb3/9ckOT7vgnS2DJaRIQPXnG89fHv42xQmtH+jJlz4yoaheyI7mUh/2IbGfdg1I9cjaSg19WnKFQ/3/jIzoN923xLbWxVMmczlg/lvPEAf+QA/AyAxPe9mrzlknEb5N5Er/VgHu7HfKX6NBfIKS9EOlj24Bm9Wss75CbFfSlLkJQIbRqi9RHiNkGs9mbCAW4vcPSoOsYAyVOS+Bkh9CYCbZNT33YMiY6kf+5mpkjF5LKfOYZSkWz/vs/gA8Zepey0bPYFjAzDZARbXeCm/J/gJ9v44eqnCbHzgS5ikIwZ3DG+VmMOci0i4KnsFeq07ZRHyfJfpGhW62KVdJFrnwJxRfNsqGuUtuC5bT6xFzoSFrHdKDb+gXwi0X8PFXnIkd5T4MK3owD+OyHp4iVmYsqP4aooc3h68+9pKX0c/TpqcJqDgKl3o73TsTurQo/l6fvr0ufnFrUnFmXr+ZkkjAxtYYiELfh1JP+MWS06OtUxrx37B6yHQF+D8MkaM2gw1KtSZOxbgkat+vc7JT8ez1Xt6qg7OWb+JogqDJid3RHqN3wxGuZHUynJpIpJgjF0z64ibnJEx7pF61r0hPCQQjvNCeweD+O1AmgP2462S3C4FPTZcbldm2G98G68='
steps:
- name: Checkout
uses: actions/[email protected]
- name: Install Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python_version }}
- name: Install Pipenv
run: python -m pip install --upgrade pipenv wheel
- id: cache-pipenv
uses: actions/cache@v1
with:
path: ~/.local/share/virtualenvs
key: ${{ runner.os }}-pipenv-${{ hashFiles('**/Pipfile.lock') }}
- name: Install Dependencies
if: steps.cache-pipenv.outputs.cache-hit != 'true'
run: |
pipenv install --dev --skip-lock
- name: Run Unit Tests
run: |
pipenv run invoke test
pipenv run coverage report
- name: CodeCov Upload
uses: codecov/codecov-action@v2
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./.coverage
fail_ci_if_error: true # optional (default = false)
verbose: true # optional (default = false)
- name: Run Integration Tests
run: pipenv run invoke e2e
lint:
strategy:
matrix:
python_version:
- 3.7
os:
- ubuntu
name: lint (${{ matrix.os }}/python-${{ matrix.python_version }})
runs-on: ${{ matrix.os }}-latest
steps:
- name: Checkout
uses: actions/[email protected]
- name: Install Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python_version }}
- name: Install Pipenv
run: python -m pip install --upgrade pipenv wheel
- name: Cache Pipenv
uses: actions/cache@v1
with:
path: ~/.local/share/virtualenvs
key: ${{ runner.os }}-pipenv-${{ hashFiles('**/Pipfile.lock') }}
- name: Install Dependencies
if: steps.cache-pipenv.outputs.cache-hit != 'true'
run: |
pipenv install --deploy --dev
- name: Lint
run: pipenv run invoke check --format --sort --diff
deploy:
needs: [build, lint]
runs-on: ubuntu-latest
env:
# Must be set so `akhileshns/heroku-deploy` doesn't fail.
# When unset, the action will try to open a browser window to prompt for login.
HEROKU_API_KEY: ${{ secrets.HEROKU_API_KEY }}
steps:
- name: Checkout
uses: actions/[email protected]
- name: Deploy to Heroku
uses: akhileshns/[email protected]
with:
heroku_api_key: ${{ secrets.HEROKU_API_KEY }}
heroku_app_name: ${{ secrets.HEROKU_APP }}
heroku_email: ${{ secrets.EMAIL }}
dontautocreate: true