Skip to content

add badge

add badge #15

name: Continues Integration
on: [
push,
pull_request
]
# for ovs
permissions:
# Required to upload SARIF file to CodeQL. See: https://github.com/github/codeql-action/issues/2117
actions: read
# Require writing security events to upload SARIF file to security tab
security-events: write
# Only need to read contents
contents: read
jobs:
scan-pr: # scan-pr
uses: google/osv-scanner-action/.github/workflows/[email protected]
with:
scan-args: |-
--recursive
--skip-git=true
--lockfile pnpm-lock.yaml
./
test: # test
needs: scan-pr
if: success()
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Cache Node.js modules
uses: actions/cache@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-node-
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: 20
- name: Install dependencies
run: npm install
working-directory: ${{ github.workspace }}
- name: Run tests
run: npm run test
working-directory: ${{ github.workspace }}