name: coverage

on:
  push:
    branches: [ master, dev ]
  pull_request:
    branches: [ master, dev ]

jobs:
  build:
    runs-on: ${{ matrix.platform }}
    strategy:
      max-parallel: 4
      matrix:
        platform:
          - ubuntu-latest
        python-version: [3.8]

    steps:
    - uses: actions/checkout@v2
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        python-version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install -r requirements.txt
        pip install -r requirements_test.txt
        pip install tox
        pip install codecov
    - name: Test
      run: |
        tox -r -e cov
    - name: Codecov
      uses: codecov/codecov-action@v1.0.6
      with:
        flags: unittests
        file: ./coverage.xml
        name: blinkpy
        fail_ci_if_error: true

name: coverage

on:
  push:
    branches: [ master, dev ]
  pull_request:
    branches: [ master, dev ]

jobs:
  build:
    runs-on: ${{ matrix.platform }}
    strategy:
      max-parallel: 4
      matrix:
        platform:
          - ubuntu-latest
        python-version: [3.8]

    steps:
    - uses: actions/checkout@v2
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        python-version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install -r requirements.txt
        pip install -r requirements_test.txt
        pip install tox
        pip install codecov
    - name: Test
      run: |
        tox -r -e cov
    - name: Codecov
      uses: codecov/codecov-action@v1.0.6
      env:
        CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
      with:
        flags: unittests
        file: ./coverage.xml
        name: blinkpy
        fail_ci_if_error: true

Add codecov token to workflow to fix upload issue
Add codecov token to workflow to fix upload issue