From f853298da15498a15cc43e198e1fa3bd1be3fe10 Mon Sep 17 00:00:00 2001 From: Frank Bria <136862992+frankbria@users.noreply.github.com> Date: Mon, 15 Jun 2026 11:54:12 -0700 Subject: [PATCH 1/2] ci(frontend): add npm run build + re-enable frontend lint (#646) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit frontend-tests CI ran coverage only — a TypeScript/build break passed PR CI and surfaced only at deploy. Frontend lint was disabled in code-quality with a "legacy" comment that contradicts CLAUDE.md. - frontend-tests: add `npm run build` step (fails PR on build break) - code-quality: re-enable frontend lint (Node setup + npm ci + npm run lint) - clear 6 eslint errors (5 named in issue + an extra unused var in page.test.tsx): dead `Input` import in CaptureGlitchModal (shipped), unused imports/vars in three test files frontend-tests remains wired into test-summary. 7 react-hooks/ exhaustive-deps warnings remain (non-failing) — out of scope. Closes #646 --- .github/workflows/test.yml | 20 +++++++++++++++++-- .../__tests__/app/proof/req_id/page.test.tsx | 2 -- .../components/proof/ProofDetailPage.test.tsx | 2 +- .../tasks/GitHubIssueImportModal.test.tsx | 3 +-- .../components/proof/CaptureGlitchModal.tsx | 1 - 5 files changed, 20 insertions(+), 8 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index f8c5094c..6088302a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -48,8 +48,20 @@ jobs: - name: Run mypy (type checking) run: uv run mypy codeframe/ - # Note: Frontend linting disabled - web-ui is legacy during v2 CLI-first refactor - # Re-enable when web-ui package.json is restored + - name: Set up Node.js + uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4 + with: + node-version: ${{ env.NODE_VERSION }} + cache: 'npm' + cache-dependency-path: 'web-ui/package-lock.json' + + - name: Install frontend dependencies + working-directory: web-ui + run: npm ci + + - name: Run frontend lint (eslint) + working-directory: web-ui + run: npm run lint # ============================================ # Static Analysis - Check for Hardcoded URLs @@ -265,6 +277,10 @@ jobs: working-directory: web-ui run: npm ci + - name: Build (fail PR on TypeScript/build break) + working-directory: web-ui + run: npm run build + - name: Run Jest tests with coverage working-directory: web-ui run: npm run test:coverage diff --git a/web-ui/__tests__/app/proof/req_id/page.test.tsx b/web-ui/__tests__/app/proof/req_id/page.test.tsx index 3ada6399..928ec3e8 100644 --- a/web-ui/__tests__/app/proof/req_id/page.test.tsx +++ b/web-ui/__tests__/app/proof/req_id/page.test.tsx @@ -66,8 +66,6 @@ const waivedReq = { }, }; -const mockEvidenceResponse = []; - describe('ProofDetailPage', () => { beforeEach(() => { jest.clearAllMocks(); diff --git a/web-ui/src/__tests__/components/proof/ProofDetailPage.test.tsx b/web-ui/src/__tests__/components/proof/ProofDetailPage.test.tsx index e44155f1..d7be1a34 100644 --- a/web-ui/src/__tests__/components/proof/ProofDetailPage.test.tsx +++ b/web-ui/src/__tests__/components/proof/ProofDetailPage.test.tsx @@ -3,7 +3,7 @@ import { render, screen, fireEvent } from '@testing-library/react'; import useSWR from 'swr'; import ProofDetailPage from '@/app/proof/[req_id]/page'; import * as storage from '@/lib/workspace-storage'; -import type { ProofEvidence, ProofRequirement, ProofEvidenceSortCol, SortDir } from '@/types'; +import type { ProofEvidence, ProofRequirement } from '@/types'; // ── Mocks ──────────────────────────────────────────────────────────────── diff --git a/web-ui/src/__tests__/components/tasks/GitHubIssueImportModal.test.tsx b/web-ui/src/__tests__/components/tasks/GitHubIssueImportModal.test.tsx index 2d21d17f..cc909fa7 100644 --- a/web-ui/src/__tests__/components/tasks/GitHubIssueImportModal.test.tsx +++ b/web-ui/src/__tests__/components/tasks/GitHubIssueImportModal.test.tsx @@ -1,9 +1,8 @@ import React from 'react'; -import { render, screen, fireEvent, waitFor, within } from '@testing-library/react'; +import { render, screen, fireEvent, waitFor } from '@testing-library/react'; import useSWR from 'swr'; import { GitHubIssueImportModal } from '@/components/tasks/GitHubIssueImportModal'; -import { integrationsApi } from '@/lib/api'; import type { GitHubIssue, GitHubIssuesResponse } from '@/types'; jest.mock('swr'); diff --git a/web-ui/src/components/proof/CaptureGlitchModal.tsx b/web-ui/src/components/proof/CaptureGlitchModal.tsx index 7769499a..00de7f62 100644 --- a/web-ui/src/components/proof/CaptureGlitchModal.tsx +++ b/web-ui/src/components/proof/CaptureGlitchModal.tsx @@ -4,7 +4,6 @@ import { useState, useEffect } from 'react'; import { Cancel01Icon } from '@hugeicons/react'; import * as DialogPrimitive from '@radix-ui/react-dialog'; import { Button } from '@/components/ui/button'; -import { Input } from '@/components/ui/input'; import { Textarea } from '@/components/ui/textarea'; import { Checkbox } from '@/components/ui/checkbox'; import { From 34b1493766d7aaf466ebc2af89670ce124e0f01c Mon Sep 17 00:00:00 2001 From: Frank Bria <136862992+frankbria@users.noreply.github.com> Date: Mon, 15 Jun 2026 12:01:34 -0700 Subject: [PATCH 2/2] ci(frontend): disable Next telemetry in CI build step (#646 review) --- .github/workflows/test.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6088302a..9a2c5c8c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -279,6 +279,8 @@ jobs: - name: Build (fail PR on TypeScript/build break) working-directory: web-ui + env: + NEXT_TELEMETRY_DISABLED: 1 run: npm run build - name: Run Jest tests with coverage