mirror of
https://github.com/bookorbit/bookorbit.git
synced 2026-11-03 00:11:37 -06:00
9b2e8c25c3
Bumps the github-actions group with 5 updates: | Package | From | To | | --- | --- | --- | | [actions/checkout](https://github.com/actions/checkout) | `7.0.0` | `7.0.1` | | [docker/login-action](https://github.com/docker/login-action) | `4.4.0` | `4.5.0` | | [actions/labeler](https://github.com/actions/labeler) | `6.2.0` | `7.0.0` | | [ossf/scorecard-action](https://github.com/ossf/scorecard-action) | `2.4.3` | `2.4.4` | | [github/codeql-action/upload-sarif](https://github.com/github/codeql-action) | `4.37.1` | `4.37.3` | Updates `actions/checkout` from 7.0.0 to 7.0.1 - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0...3d3c42e5aac5ba805825da76410c181273ba90b1) Updates `docker/login-action` from 4.4.0 to 4.5.0 - [Release notes](https://github.com/docker/login-action/releases) - [Commits](https://github.com/docker/login-action/compare/af1e73f918a031802d376d3c8bbc3fe56130a9b0...06fb636fac595d6fb4b28a5dfcb21a6f5091859c) Updates `actions/labeler` from 6.2.0 to 7.0.0 - [Release notes](https://github.com/actions/labeler/releases) - [Commits](https://github.com/actions/labeler/compare/b8dd2d9be0f68b860e7dae5dae7d772984eacd6d...bf12e9b00b37c5c0ca2b87b79b2daf7891dbda13) Updates `ossf/scorecard-action` from 2.4.3 to 2.4.4 - [Release notes](https://github.com/ossf/scorecard-action/releases) - [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md) - [Commits](https://github.com/ossf/scorecard-action/compare/4eaacf0543bb3f2c246792bd56e8cdeffafb205a...2d1146689b8cda280b9bc96326124645441f03bc) Updates `github/codeql-action/upload-sarif` from 4.37.1 to 4.37.3 - [Release notes](https://github.com/github/codeql-action/releases) - [Changelog](https://github.com/github/codeql-action/blob/main/CHANGELOG.md) - [Commits](https://github.com/github/codeql-action/compare/7188fc363630916deb702c7fdcf4e481b751f97a...e4fba868fa4b1b91e1fdab776edc8cfbe6e9fb81) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: 7.0.1 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: github-actions - dependency-name: docker/login-action dependency-version: 4.5.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: github-actions - dependency-name: actions/labeler dependency-version: 7.0.0 dependency-type: direct:production update-type: version-update:semver-major dependency-group: github-actions - dependency-name: ossf/scorecard-action dependency-version: 2.4.4 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: github-actions - dependency-name: github/codeql-action/upload-sarif dependency-version: 4.37.3 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: github-actions ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: neon <18559658+neonsolstice@users.noreply.github.com>
100 lines
2.9 KiB
YAML
100 lines
2.9 KiB
YAML
name: E2E Runner (reusable)
|
|
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
suite-id:
|
|
description: "E2E suite id from scripts/e2e/suite-registry.mjs (e.g. scanner-scenarios)"
|
|
required: true
|
|
type: string
|
|
check-name:
|
|
description: "Name shown in the GitHub checks UI"
|
|
required: true
|
|
type: string
|
|
artifact-name:
|
|
description: "Name for the uploaded artifact"
|
|
required: true
|
|
type: string
|
|
job-timeout-minutes:
|
|
description: "Job timeout in minutes"
|
|
required: false
|
|
type: number
|
|
default: 45
|
|
vitest-args:
|
|
description: "Optional extra args forwarded to vitest (for shard/testNamePattern reruns)"
|
|
required: false
|
|
type: string
|
|
default: ""
|
|
|
|
env:
|
|
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: "true"
|
|
NODE_VERSION: "24"
|
|
PNPM_VERSION: "10"
|
|
E2E_DATABASE_URL: postgres://bookorbit:bookorbit@localhost:5432/bookorbit_e2e
|
|
NODE_ENV: test
|
|
JWT_SECRET: scanner-e2e-secret-1234
|
|
JWT_EXPIRES_IN: 15m
|
|
JWT_REFRESH_EXPIRES_IN: 7d
|
|
BOOKS_PATH: ../local/data
|
|
APP_URL: http://localhost:5173
|
|
|
|
jobs:
|
|
run-suite:
|
|
name: ${{ inputs.check-name }}
|
|
runs-on: ubuntu-latest
|
|
timeout-minutes: ${{ inputs.job-timeout-minutes }}
|
|
permissions:
|
|
contents: read
|
|
checks: write
|
|
services:
|
|
postgres:
|
|
image: pgvector/pgvector:pg18
|
|
env:
|
|
POSTGRES_USER: bookorbit
|
|
POSTGRES_PASSWORD: bookorbit
|
|
POSTGRES_DB: bookorbit
|
|
ports:
|
|
- 5432:5432
|
|
options: >-
|
|
--health-cmd="pg_isready -U bookorbit"
|
|
--health-interval=5s
|
|
--health-timeout=5s
|
|
--health-retries=20
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
|
|
|
- name: Set up Node.js and pnpm
|
|
uses: ./.github/actions/setup-node-pnpm
|
|
with:
|
|
node-version: ${{ env.NODE_VERSION }}
|
|
pnpm-version: ${{ env.PNPM_VERSION }}
|
|
prefetch: "true"
|
|
|
|
- name: Run e2e suite
|
|
shell: bash
|
|
run: |
|
|
if [ -n "${{ inputs.vitest-args }}" ]; then
|
|
pnpm run e2e:run -- ${{ inputs.suite-id }} ${{ inputs.vitest-args }}
|
|
else
|
|
pnpm run e2e:run -- ${{ inputs.suite-id }}
|
|
fi
|
|
|
|
- name: Publish test report annotations
|
|
if: always()
|
|
uses: EnricoMi/publish-unit-test-result-action@d0a4676d0e0b938bc201470d88276b7c74c712b3 # v2
|
|
with:
|
|
check_name: ${{ inputs.check-name }}
|
|
files: test-results/server/*-e2e-junit.xml
|
|
fail_on: nothing
|
|
comment_mode: off
|
|
|
|
- name: Upload e2e artifacts
|
|
if: always()
|
|
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
|
with:
|
|
name: ${{ inputs.artifact-name }}
|
|
path: test-results/server
|
|
retention-days: 7
|