~naglis/aio_mpv_ipc

ref: 48b238f472f6ba16362165ea20bd25bca3548c1b aio_mpv_ipc/.github/workflows/ci.yml -rw-r--r-- 1.3 KiB
48b238f4Naglis Jonaitis Lower error log level 1 year, 4 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: Continuous Integration
on: [push, pull_request]
jobs:
  build:
    runs-on: ubuntu-18.04
    strategy:
      fail-fast: false
      matrix:
        python: ['3.7']
    steps:
      - uses: actions/checkout@v1

      - name: Set up Python ${{ matrix.python }}
        uses: actions/setup-python@v1
        with:
          python-version: ${{ matrix.python }}

      - name: Install mpv
        run: |
            sudo add-apt-repository ppa:mc3man/mpv-tests -y
            sudo apt-get update -q
            sudo apt-get install mpv

      - name: Install dependencies
        run: |
          curl -sSL https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py | python
          source $HOME/.poetry/env
          poetry install -v

      - name: Test
        run: |
          source $HOME/.poetry/env
          poetry run pytest -vv --cov aio_mpv_ipc --cov-report term --cov-report xml

      - name: Lint
        run: |
          source $HOME/.poetry/env
          poetry run flake8 aio_mpv_ipc/ tests/
          poetry run black --check aio_mpv_ipc/ tests/
          poetry run bandit -r aio_mpv_ipc/

      - name: Code coverage
        continue-on-error: true
        env:
          CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
        run: |
          source $HOME/.poetry/env
          poetry run codecov --token ${CODECOV_TOKEN}