Skip to content

add codecov to ci

add codecov to ci #12

Workflow file for this run

name: tests
on:
push:
branches:
- main
- dev
jobs:
tests:
runs-on: ubuntu-latest
name: tests
env:
XATA_API_KEY: ${{ secrets.XATA_API_KEY }}
XATA_DB: ${{secrets.XATA_DB}}
SUDO_SECRET: ${{ secrets.SUDO_SECRET }}
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
steps:
- uses: actions/checkout@v4
- run: |
touch .dev.vars
echo SUDO_SECRET="$SUDO_SECRET" >> .dev.vars
echo XATA_API_KEY="$XATA_API_KEY" >> .dev.vars
echo XATA_DB="$XATA_DB" >> .dev.vars
- run: npm install
- run: npm run coverage
- uses: codecov/codecov-action@v4
with:
file: ./coverage/lcov.info