Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active
TypeScript aianthropicartifactsawsazurechatgptchatgpt-cloneclaudeclonedeepseekgeminigooglegpt-5librechatmcpo1openairesponses-apivisionwebui
📒 ci: Upload Per-Test Jest Results From Review Workflows (#16110)
Danny Avilaba44443fdb23
diff --git a/.github/workflows/backend-review.yml b/.github/workflows/backend-review.ymlindex 6271abc91f..82d0088cdc 100644--- a/.github/workflows/backend-review.yml+++ b/.github/workflows/backend-review.yml@@ -433,7 +433,9 @@ jobs:- name: Run unit tests (shard ${{ matrix.shard }}/3)env:SELECTED: ${{ needs.codegraph_select.outputs.api_files }}+ JEST_JSON: --json --outputFile=${{ github.workspace }}/jest-results/jest-results-api-${{ matrix.shard }}.jsonrun: |+ mkdir -p "$GITHUB_WORKSPACE/jest-results"cd api# A selected path can be stale in exactly two ways at this checkout (Codex P2, #15145 r6):# deleted on the branch — dropped, which matches full CI (the file runs nowhere) — or@@ -448,14 +450,26 @@ jobs:KEEP="${KEEP# }"if [ -z "$KEEP" ]; thenecho "no selected test file exists at HEAD (stale selection); running FULL"- npm run test:ci -- --shard=${{ matrix.shard }}/3+ npm run test:ci -- --shard=${{ matrix.shard }}/3 $JEST_JSONelseecho "codegraph: $(echo $KEEP | wc -w) selected test files (safe mode)"- npm run test:ci -- --shard=${{ matrix.shard }}/3 --passWithNoTests --runTestsByPath $KEEP+ npm run test:ci -- --shard=${{ matrix.shard }}/3 --passWithNoTests --runTestsByPath $KEEP $JEST_JSONfielse- npm run test:ci -- --shard=${{ matrix.shard }}/3+ npm run test:ci -- --shard=${{ matrix.shard }}/3 $JEST_JSONfi+ # Per-test results keyed by head SHA (run.head_sha), for the codegraph test-evidence feed.+ # Never part of the gate: it cannot fail the job, and a re-run overwrites its own artifact.+ - name: Upload Jest results+ if: ${{ !cancelled() }}+ continue-on-error: true+ uses: actions/upload-artifact@v6+ with:+ name: jest-results-api-${{ matrix.shard }}+ path: jest-results/+ retention-days: 7+ if-no-files-found: ignore+ overwrite: truetest-data-provider:name: 'Tests: data-provider'@@ -509,7 +523,9 @@ jobs:- name: Run unit testsenv:SELECTED: ${{ needs.codegraph_select.outputs.dataprovider_files }}+ JEST_JSON: --json --outputFile=${{ github.workspace }}/jest-results/jest-results-data-provider.jsonrun: |+ mkdir -p "$GITHUB_WORKSPACE/jest-results"cd packages/data-providerif [ -n "$SELECTED" ]; thenKEEP=""@@ -519,14 +535,26 @@ jobs:KEEP="${KEEP# }"if [ -z "$KEEP" ]; thenecho "no selected test file exists at HEAD (stale selection); running FULL"- npm run test:ci+ npm run test:ci -- $JEST_JSONelseecho "codegraph: $(echo $KEEP | wc -w) selected test files (safe mode)"- npm run test:ci -- --passWithNoTests --runTestsByPath $KEEP+ npm run test:ci -- --passWithNoTests --runTestsByPath $KEEP $JEST_JSONfielse- npm run test:ci+ npm run test:ci -- $JEST_JSONfi+ # Per-test results keyed by head SHA (run.head_sha), for the codegraph test-evidence feed.+ # Never part of the gate: it cannot fail the job, and a re-run overwrites its own artifact.+ - name: Upload Jest results+ if: ${{ !cancelled() }}+ continue-on-error: true+ uses: actions/upload-artifact@v6+ with:+ name: jest-results-data-provider+ path: jest-results/+ retention-days: 7+ if-no-files-found: ignore+ overwrite: truetest-data-schemas:name: 'Tests: data-schemas'@@ -586,7 +614,9 @@ jobs:- name: Run unit testsenv:SELECTED: ${{ needs.codegraph_select.outputs.dataschemas_files }}+ JEST_JSON: --json --outputFile=${{ github.workspace }}/jest-results/jest-results-data-schemas.jsonrun: |+ mkdir -p "$GITHUB_WORKSPACE/jest-results"cd packages/data-schemasif [ -n "$SELECTED" ]; thenKEEP=""@@ -596,14 +626,26 @@ jobs:KEEP="${KEEP# }"if [ -z "$KEEP" ]; thenecho "no selected test file exists at HEAD (stale selection); running FULL"- npm run test:ci+ npm run test:ci -- $JEST_JSONelseecho "codegraph: $(echo $KEEP | wc -w) selected test files (safe mode)"- npm run test:ci -- --passWithNoTests --runTestsByPath $KEEP+ npm run test:ci -- --passWithNoTests --runTestsByPath $KEEP $JEST_JSONfielse- npm run test:ci+ npm run test:ci -- $JEST_JSONfi+ # Per-test results keyed by head SHA (run.head_sha), for the codegraph test-evidence feed.+ # Never part of the gate: it cannot fail the job, and a re-run overwrites its own artifact.+ - name: Upload Jest results+ if: ${{ !cancelled() }}+ continue-on-error: true+ uses: actions/upload-artifact@v6+ with:+ name: jest-results-data-schemas+ path: jest-results/+ retention-days: 7+ if-no-files-found: ignore+ overwrite: truetest-packages-api:name: 'Tests: @librechat/api (shard ${{ matrix.shard }}/4)'@@ -677,7 +719,9 @@ jobs:- name: Run unit tests (shard ${{ matrix.shard }}/4)env:SELECTED: ${{ needs.codegraph_select.outputs.pkgapi_files }}+ JEST_JSON: --json --outputFile=${{ github.workspace }}/jest-results/jest-results-packages-api-${{ matrix.shard }}.jsonrun: |+ mkdir -p "$GITHUB_WORKSPACE/jest-results"cd packages/apiif [ -n "$SELECTED" ]; thenKEEP=""@@ -687,11 +731,23 @@ jobs:KEEP="${KEEP# }"if [ -z "$KEEP" ]; thenecho "no selected test file exists at HEAD (stale selection); running FULL"- npm run test:ci -- --shard=${{ matrix.shard }}/4+ npm run test:ci -- --shard=${{ matrix.shard }}/4 $JEST_JSONelseecho "codegraph: $(echo $KEEP | wc -w) selected test files (safe mode)"- npm run test:ci -- --shard=${{ matrix.shard }}/4 --passWithNoTests --runTestsByPath $KEEP+ npm run test:ci -- --shard=${{ matrix.shard }}/4 --passWithNoTests --runTestsByPath $KEEP $JEST_JSONfielse- npm run test:ci -- --shard=${{ matrix.shard }}/4+ npm run test:ci -- --shard=${{ matrix.shard }}/4 $JEST_JSONfi+ # Per-test results keyed by head SHA (run.head_sha), for the codegraph test-evidence feed.+ # Never part of the gate: it cannot fail the job, and a re-run overwrites its own artifact.+ - name: Upload Jest results+ if: ${{ !cancelled() }}+ continue-on-error: true+ uses: actions/upload-artifact@v6+ with:+ name: jest-results-packages-api-${{ matrix.shard }}+ path: jest-results/+ retention-days: 7+ if-no-files-found: ignore+ overwrite: truediff --git a/.github/workflows/frontend-review.yml b/.github/workflows/frontend-review.ymlindex 8fec3bac4c..40ebe5b722 100644--- a/.github/workflows/frontend-review.yml+++ b/.github/workflows/frontend-review.yml@@ -304,7 +304,9 @@ jobs:- name: Run unit testsenv:SELECTED: ${{ needs.codegraph_select.outputs.clientpkg_files }}+ JEST_JSON: --json --outputFile=${{ github.workspace }}/jest-results/jest-results-packages-client.jsonrun: |+ mkdir -p "$GITHUB_WORKSPACE/jest-results"# A selected path can be stale in exactly two ways at this checkout (Codex P2, #15145 r6):# deleted on the branch — dropped, which matches full CI (the file runs nowhere) — or# renamed, where the NEW path is a changed test file and is selected independently. If@@ -318,15 +320,27 @@ jobs:KEEP="${KEEP# }"if [ -z "$KEEP" ]; thenecho "no selected test file exists at HEAD (stale selection); running FULL"- npm run test:ci+ npm run test:ci -- $JEST_JSONelseecho "codegraph: $(echo $KEEP | wc -w) selected test files (safe mode)"- npm run test:ci -- --passWithNoTests --runTestsByPath $KEEP+ npm run test:ci -- --passWithNoTests --runTestsByPath $KEEP $JEST_JSONfielse- npm run test:ci+ npm run test:ci -- $JEST_JSONfiworking-directory: packages/client+ # Per-test results keyed by head SHA (run.head_sha), for the codegraph test-evidence feed.+ # Never part of the gate: it cannot fail the job, and a re-run overwrites its own artifact.+ - name: Upload Jest results+ if: ${{ !cancelled() }}+ continue-on-error: true+ uses: actions/upload-artifact@v6+ with:+ name: jest-results-packages-client+ path: jest-results/+ retention-days: 7+ if-no-files-found: ignore+ overwrite: truetest-ubuntu:name: 'Tests: Ubuntu (shard ${{ matrix.shard }}/2)'@@ -378,7 +392,9 @@ jobs:- name: Run unit tests (shard ${{ matrix.shard }}/2)env:SELECTED: ${{ needs.codegraph_select.outputs.client_files }}+ JEST_JSON: --json --outputFile=${{ github.workspace }}/jest-results/jest-results-client-${{ matrix.shard }}.jsonrun: |+ mkdir -p "$GITHUB_WORKSPACE/jest-results"if [ -n "$SELECTED" ]; thenKEEP=""for f in $SELECTED; do@@ -387,15 +403,27 @@ jobs:KEEP="${KEEP# }"if [ -z "$KEEP" ]; thenecho "no selected test file exists at HEAD (stale selection); running FULL"- npm run test:ci -- --shard=${{ matrix.shard }}/2+ npm run test:ci -- --shard=${{ matrix.shard }}/2 $JEST_JSONelseecho "codegraph: $(echo $KEEP | wc -w) selected test files (safe mode)"- npm run test:ci -- --shard=${{ matrix.shard }}/2 --passWithNoTests --runTestsByPath $KEEP+ npm run test:ci -- --shard=${{ matrix.shard }}/2 --passWithNoTests --runTestsByPath $KEEP $JEST_JSONfielse- npm run test:ci -- --shard=${{ matrix.shard }}/2+ npm run test:ci -- --shard=${{ matrix.shard }}/2 $JEST_JSONfiworking-directory: client+ # Per-test results keyed by head SHA (run.head_sha), for the codegraph test-evidence feed.+ # Never part of the gate: it cannot fail the job, and a re-run overwrites its own artifact.+ - name: Upload Jest results+ if: ${{ !cancelled() }}+ continue-on-error: true+ uses: actions/upload-artifact@v6+ with:+ name: jest-results-client-${{ matrix.shard }}+ path: jest-results/+ retention-days: 7+ if-no-files-found: ignore+ overwrite: truebuild-verify:name: Vite build verification