Tests / writer-pipeline tests (push) Failing after 1s
Tests / bridge tests (push) Failing after 1s
Tests / frontend lib tests (push) Failing after 1s
Tests / writer-pipeline tests (pull_request) Successful in 52s
Tests / bridge tests (pull_request) Successful in 25s
Tests / frontend lib tests (pull_request) Successful in 29s
87 new tests covering previously untested pure functions: - writer-pipeline: token-metrics, store (canonicalUrl/itemId/upsertItem/shortlist), config-load - bridge: ranking (freshness/relevance/rank/filter/take_top_n), aggregator-mapper - frontend/lib: format, ui-i18n, public-origin Adds test:coverage scripts (node --experimental-test-coverage) and Gitea CI workflow. writer-pipeline now reports 95.91% line coverage. Co-Authored-By: Paperclip <[email protected]>
60 lines
1.4 KiB
YAML
60 lines
1.4 KiB
YAML
name: Tests
|
|
|
|
on:
|
|
push:
|
|
branches: ["**"]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
writer-pipeline:
|
|
name: writer-pipeline tests
|
|
runs-on: ubuntu-latest
|
|
defaults:
|
|
run:
|
|
working-directory: writer-pipeline
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: "22"
|
|
cache: "npm"
|
|
cache-dependency-path: writer-pipeline/package-lock.json
|
|
- run: npm ci
|
|
- name: Run tests with coverage
|
|
run: npm run test:coverage
|
|
|
|
bridge:
|
|
name: bridge tests
|
|
runs-on: ubuntu-latest
|
|
defaults:
|
|
run:
|
|
working-directory: bridge
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: "22"
|
|
cache: "npm"
|
|
cache-dependency-path: bridge/package-lock.json
|
|
- run: npm ci
|
|
- name: Run tests with coverage
|
|
run: npm run test:coverage
|
|
|
|
frontend-lib:
|
|
name: frontend lib tests
|
|
runs-on: ubuntu-latest
|
|
defaults:
|
|
run:
|
|
working-directory: frontend
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: "22"
|
|
cache: "npm"
|
|
cache-dependency-path: frontend/package-lock.json
|
|
- run: npm install
|
|
- name: Run lib tests with coverage
|
|
run: npm run test:coverage
|