| on: [ "push", "pull_request" ] |
| |
| name: Test Coveralls |
| |
| jobs: |
| |
| build: |
| name: Coverage |
| runs-on: ubuntu-latest |
| steps: |
| |
| - uses: actions/checkout@v1 |
| |
| - uses: actions/setup-python@v2 |
| with: |
| python-version: '3.12' |
| architecture: 'x64' |
| |
| |
| - name: Install Dependency |
| run: | |
| python -m pip install -r dev-requirements.txt |
| python -m pip install pytest coveralls |
| |
| - name: Run Coverage |
| run: | |
| python -m pytest --cov=fastapi_casbin_auth tests/ |
| pip install "urllib3<2" --force-reinstall |
| pip show urllib3 |
| coveralls --service=github |
| env: |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
| |
| # - name: Coveralls |
| # uses: coverallsapp/github-action@master |
| # with: |
| # github-token: ${{ secrets.GITHUB_TOKEN }} |
| # path-to-lcov: ${{ github.workspace }}/.coverage |