-
Notifications
You must be signed in to change notification settings - Fork 0
ci: run unit tests and biome lint on every pull request #7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -50,3 +50,36 @@ jobs: | |
| context: . | ||
| file: ./docker/Dockerfile | ||
| tags: documenso-${{ github.sha }} | ||
|
|
||
| unit_tests: | ||
| name: Unit tests | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 30 | ||
| env: | ||
| # The crypto helpers read these at import time. The values only need to | ||
| # satisfy the boot guard's shape; they protect nothing in CI. | ||
| NEXT_PRIVATE_ENCRYPTION_KEY: ci-only-primary-key-0123456789abcdef | ||
| NEXT_PRIVATE_ENCRYPTION_SECONDARY_KEY: ci-only-secondary-key-0123456789 | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| fetch-depth: 2 | ||
|
Comment on lines
+64
to
+67
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔒 Security & Privacy | 🛡️ Analyzed with Security Review | 🟠 Major | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -eu
printf '%s\n' '--- checkout occurrences ---'
rg -n -C 5 'actions/checkout|pull_request|permissions:|GITHUB_TOKEN|persist-credentials|docker build|npm (ci|run)|vitest' .github/workflows/ci.yml
printf '%s\n' '--- workflow outline ---'
sed -n '1,220p' .github/workflows/ci.ymlRepository: DOS/Crove-Sign Length of output: 3848 Sensitive Data Exposure Reachability: External Disable checkout credential persistence in all four checkout steps. 🧰 Tools🪛 zizmor (1.29.0)[warning] 64-67: credential persistence through GitHub Actions artifacts (artipacked): does not set persist-credentials: false (artipacked) [warning] 1-86: overly broad permissions (excessive-permissions): default permissions used due to no permissions: block (excessive-permissions) [warning] 54-72: overly broad permissions (excessive-permissions): default permissions used due to no permissions: block (excessive-permissions) 🤖 Prompt for AI Agents |
||
|
|
||
| - uses: ./.github/actions/node-install | ||
|
|
||
| - name: Run unit tests | ||
| run: npm run test -w @documenso/lib | ||
|
|
||
| lint: | ||
| name: Lint | ||
| runs-on: ubuntu-latest | ||
| timeout-minutes: 15 | ||
| steps: | ||
| - name: Checkout | ||
| uses: actions/checkout@v4 | ||
|
|
||
| - uses: ./.github/actions/node-install | ||
|
|
||
| - name: Biome | ||
| run: npm run lint | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔒 Security & Privacy | 🛡️ Analyzed with Security Review | 🟠 Major | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
Repository: DOS/Crove-Sign
Length of output: 2931
Security Misconfiguration
Reachability: External
CWE: CWE-732 — Incorrect Permission Assignment for Critical Resource
Set explicit least-privilege permissions for the workflow. The
pull_requestjobs execute repository-controlled code. If repository defaults grant write access, that code can useGITHUB_TOKENto modify GitHub resources. Add workflow-levelpermissions: contents: read, unless repository policy already enforces read-only permissions.🧰 Tools
🪛 zizmor (1.29.0)
[warning] 1-86: overly broad permissions (excessive-permissions): default permissions used due to no permissions: block
(excessive-permissions)
[warning] 54-72: overly broad permissions (excessive-permissions): default permissions used due to no permissions: block
(excessive-permissions)
🤖 Prompt for AI Agents
Source: Linters/SAST tools