chore(layout): 정리 3·4단계로 루트를 합치고 배치 규칙을 검사로 둔다 #14
@@ -170,6 +170,9 @@ jobs:
|
||||
artifacts/security/supply-chain-coherence.json \
|
||||
artifacts/security/supply-chain-verification.json \
|
||||
artifacts/security/vulnerability-report.json \
|
||||
config/schemas/artifacts/build-manifest.schema.json \
|
||||
config/schemas/artifacts/dependency-inventory.schema.json \
|
||||
config/schemas/artifacts/supply-chain-verification.schema.json \
|
||||
config/security/dependency-baseline.approval.json \
|
||||
config/security/dependency-baseline.json \
|
||||
config/security/dependency-change-evidence.json \
|
||||
@@ -177,9 +180,6 @@ jobs:
|
||||
config/security/secret-scan-policy.json \
|
||||
config/security/vulnerability-exceptions.json \
|
||||
config/security/vulnerability-policy.json \
|
||||
schemas/artifacts/build-manifest.schema.json \
|
||||
schemas/artifacts/dependency-inventory.schema.json \
|
||||
schemas/artifacts/supply-chain-verification.schema.json \
|
||||
scripts/contracts/release-artifacts.ts \
|
||||
scripts/create-release-candidate.ts \
|
||||
scripts/generate-supply-chain.ts \
|
||||
|
||||
@@ -23,9 +23,6 @@ artifacts/runbooks/*
|
||||
!artifacts/tests/
|
||||
artifacts/tests/*
|
||||
!artifacts/tests/.gitkeep
|
||||
!artifacts/tests/a11y-manual/
|
||||
artifacts/tests/a11y-manual/*
|
||||
!artifacts/tests/a11y-manual/*.md
|
||||
|
||||
# Local environment overrides. `.env.example` is the tracked template; every
|
||||
# other `.env*` file is a developer's own machine and never enters the repo.
|
||||
|
||||
+14
-2
@@ -43,7 +43,7 @@
|
||||
|
||||
## 미출시 — `48c7695b` → 정리 단계
|
||||
|
||||
2026-11-07 소유자가 지시한 저장소 정리다(design-docs `repo-structure/04-frontend-layout.md` 9.2절, 결정은 `repo-structure/README.md` 3.4절). 범위는 `main` `48c7695b`(PR #9 병합) 다음부터다. 1단계(PR #11, `85f941c4`~`121e1125`, `main` `f33e4778`에 합침)와 2단계(브랜치 `chore/layout-2-sample-removal`, `c7e80f2f`부터 브랜치 끝까지)를 담는다. 3단계(합치기)는 아직 없다. 기준점 `48c7695b`를 빼면 이 절의 해시는 모두 이 범위에 있다.
|
||||
2026-11-07 소유자가 지시한 저장소 정리다(design-docs `repo-structure/04-frontend-layout.md` 9.2절, 결정은 `repo-structure/README.md` 3.4절). 범위는 `main` `48c7695b`(PR #9 병합) 다음부터다. 1단계(PR #11, `85f941c4`~`121e1125`, `main` `f33e4778`에 합침), 2단계(브랜치 `chore/layout-2-sample-removal`, `c7e80f2f`~`ad3a071f`), 3단계(합치기)와 4단계(배치 규칙 검사)(브랜치 `chore/layout-3-merge`, `bf485f44`부터 브랜치 끝까지)를 담는다. 기준점 `48c7695b`를 빼면 이 절의 해시는 모두 이 범위에 있다.
|
||||
|
||||
### 먼저 할 일 (BREAKING)
|
||||
|
||||
@@ -62,10 +62,16 @@
|
||||
4. **CI 계약 기준선과 workflow를 자기 값으로 다시 기록한 프로젝트는 다시 기록한다.** FE-GATE-007에서 `test:reference-feature` 명령과 그 산출물이, FE-GATE-009·028에서 지운 라우트의 수동 접근성 기록 산출물 4개가 빠졌다. `CI_CONTRACT_BASELINE_OWNER=<팀> CI_CONTRACT_BASELINE_REASON=<이유> corepack pnpm update:ci-contract-baseline`, 그다음 `corepack pnpm generate:ci-workflow` (`e3c8db48`)
|
||||
5. **초기 JS 기록을 다시 쓴다.** `config/scale/feature-shape-ceilings.json`의 `initialJavascript`에 `firstFeatureGzipBytes`가 더해졌고, 측정은 참조 기능 대신 생성 기능을 복사해 잰다. `node scripts/scale/measure-feature-shape-growth.ts --initial-baseline --write`. 다시 쓰지 않으면 `test:unit`이 기록과 빌드가 다르다며 실패한다 (`b2042de9`)
|
||||
6. **`src/features/` 아래에 기능이 아닌 폴더를 두었으면 밖으로 옮긴다.** 생성기는 `NOT_A_FEATURE` 표식을 더 읽지 않는다. 선언 없는 폴더는 `src/features/<dir> has no feature-module.ts; add one, or keep code that is no feature outside src/features`로 실패한다. 템플릿의 local-draft 샘플은 `tests/fixtures/indexeddb-consumer/`로 옮겼다 (`b72cd7d4`)
|
||||
7. **음성 타입 fixture를 더한 프로젝트는 첫 줄에 기대를 쓰고 fixture별 tsconfig·script를 지운다.** 템플릿은 `tests/fixtures/typecheck/tsconfig.<이름>.json` 23개와 `check:types:fixture*` script 23개를 `check:types:fixtures` 하나(`scripts/check-type-fixtures.ts`)로 합쳤다. `invalid-*.ts(x)` fixture마다 첫 줄에 `// expect: TS2322`(실패와 그 진단) 또는 `// expect: pass`를 쓴다. 없으면 `check:types:fixtures`가 `` missing `// expect:` first line ``으로 실패한다. 자기 `config/ci/product-gates.json`이 옛 명령 id(`check-types-fixture-*`)를 참조했으면 `check-types-fixtures`로 바꾼다 (`bf485f44`)
|
||||
8. **`tsconfig.recipes.json`·`tsconfig.web-worker.json`과 그 script(`check:types:recipes`, `check:types:web-worker`)가 없어졌다.** recipe는 `check:types:test`가 검사한다. 자기 recipe tsconfig를 고쳤으면 그 옵션을 `tsconfig.test.json`에 옮긴다. Web Worker 코드를 들인 프로젝트는 매뉴얼 03 C절 「Web Worker를 들일 때 tsconfig 더하기」대로 tsconfig와 script를 되살린다. `check:types` 끝의 `check-typecheck-inputs.ts`는 tsc에 넘기는 tsconfig의 입력이 0개면 `Typecheck inputs: FAIL (no input files: <tsconfig>)`로 실패한다 (`bf485f44`)
|
||||
9. **수동 a11y 기록을 옮긴다.** `artifacts/tests/a11y-manual/<ROUTE_ID>.md` → `docs/accessibility/route-reviews/<ROUTE_ID>.md`(자기 라우트 기록도 `git mv`). `.gitignore`가 더는 `artifacts/` 아래 `.md`를 들이지 않는다. 남기면 `tests/unit/tracked-artifacts.test.ts`가 그 파일을 이름으로 실패시키고, 옮기지 않으면 `verify:documentation`이 `docs/accessibility/route-reviews/ has no record for route IDs: <ids>`로 실패한다 (`79dc945a`)
|
||||
10. **루트 `schemas/`를 `config/schemas/`로 옮긴다.** 산출물 스키마는 `config/schemas/artifacts/`, recipe 카탈로그 스키마는 `config/schemas/recipes/`다. 자기 스키마를 `schemas/`에 두었으면 같은 곳으로 옮기고 `$schema` 상대 경로를 고친다. hosting 응답 fixture는 `config/hosting/response-headers.fixture.json` → `tests/fixtures/hosting/response-headers.json` (`79dc945a`)
|
||||
11. **자기 루트 항목을 등록부에 더한다.** 루트 항목마다 `config/repository-layout.json`에 종류·역할·읽는 곳을 적는다. 제품이 더한 루트 항목(예: `Dockerfile`, `compose.yaml`, `deploy/`)이 없으면 `tests/unit/repository-layout.test.ts`가 `add an entry with its role to config/repository-layout.json`으로 실패한다. 비밀값 검사 범위에 넣을 항목은 `sets`에 `secret-scan`을 적고 `config/security/secret-scan-policy.json`의 `trackedRoots`에도 같은 이름을 더한다. 둘이 다르면 같은 시험이 실패한다. 루트 경로 목록을 코드에 새로 적지 말고 `selectRepositoryPaths(<집합>)`으로 고른다(매뉴얼 03 E절 R2) (`79dc945a`)
|
||||
12. **CI 계약 기준선을 자기 값으로 다시 기록한 프로젝트는 다시 기록한다.** FE-GATE-003 명령이 25개에서 2개로, FE-GATE-009·028의 수동 a11y 기록 산출물 경로와 id가 바뀌었다. 4단계와 같은 명령이다 (`bf485f44`, `79dc945a`)
|
||||
|
||||
#### 옮긴 뒤 확인
|
||||
|
||||
1. 로컬 merge 게이트 14개를 돈다. 이 절 때문에 먼저 볼 것: `check:registries`(3단계), `check:ci`(4단계), `test:unit`(5단계), `generate:feature-index`(6단계), `verify:documentation`(지운 샘플 경로를 적은 자기 문서), `test:sample-removal`(인자 없이 돌면 목록이 빈 템플릿에서는 `SKIP`을 출력한다).
|
||||
1. 로컬 merge 게이트 14개를 돈다. 이 절 때문에 먼저 볼 것: `check:registries`(3단계), `check:ci`(4·12단계), `test:unit`(5·9·11단계), `generate:feature-index`(6단계), `check:types`·`check:types:fixtures`(7·8단계), `verify:documentation`(지운 샘플 경로를 적은 자기 문서, 9단계, 매뉴얼 03 E절 R6·R7), `test:sample-removal`(인자 없이 돌면 목록이 빈 템플릿에서는 `SKIP`을 출력한다).
|
||||
2. 시각 골든: 갤러리 두 장(`design-system-gallery-dark`, `state-surfaces-light`)은 이제 Storybook 정적 빌드의 story를 찍는다. 자기 골든을 다시 찍은 프로젝트는 `corepack pnpm test:visual:update`로 그 둘을 다시 찍는다.
|
||||
3. `/examples/ui`·`/examples/states`·`/examples/auth`를 열던 자기 e2e는 플랫폼 라우트나 자기 화면으로 옮긴다. 템플릿의 그런 spec은 옮겼다(아래 표).
|
||||
|
||||
@@ -80,9 +86,13 @@
|
||||
| [계약] | 규모 측정이 참조 기능 대신 생성 기능을 복사해 잰다(`planShapeFeatures`). `initialJavascript`에 `firstFeatureGzipBytes`(기능이 없는 템플릿에 첫 기능을 더할 때의 비용)가 생겼고, context 비용은 둘째 기능을 새 context에 둘 때와 같은 context에 둘 때의 차이다. 기록: 템플릿 194,354 B·17파일, 첫 기능 6,327 B, 기능 하나 539 B, context 하나 4 B. 성장 기준선(0·25·100개)도 다시 쟀다. 위 "먼저 할 일" 5 | `scripts/scale/measure-feature-shape-growth.ts`, `config/scale/` | `b2042de9`, `9c87cc4d` |
|
||||
| [계약] | 생성기가 `NOT_A_FEATURE` 표식을 읽지 않는다. local-draft 샘플은 IndexedDB 소비자 시험 fixture(`tests/fixtures/indexeddb-consumer/`)가 됐다. 위 "먼저 할 일" 6 | `scripts/generate-product-feature-index.ts`, `recipes/frontend-capabilities/indexeddb-feature-capability.ts` | `b72cd7d4` |
|
||||
| [계약] | 브라우저 soak(`scripts/scale/browser-soak.ts`, nightly 밖)이 기본으로 생성 기능을 넣은 빌드를 만들어 그 목록 라우트에서 실패하는 백엔드를 관찰한다. `--dist`를 주면 `--feature-route`도 준다. 결과 칸 이름이 `featureVisits`·`settledFeatureVisits`·`apiRequestsPerFeatureVisit`으로 바뀌었다 | `scripts/scale/browser-soak.ts` | `e3c8db48` |
|
||||
| [계약] **BREAKING** | 음성 타입 fixture 23개를 실행기 하나로 돈다. fixture 첫 줄의 `// expect:`가 기대이고, 판정은 전과 같다(tsc exit 1과 `error TS<code>:`). fixture별 결과와 맞은 진단 줄을 출력한다. `TelemetryPort.emit` 인자를 넓히는 변이(0925/07-05)에서 실패하는 것을 확인했다. recipes tsconfig는 test에 합쳤고 web-worker tsconfig(0파일 검사)는 지웠다(결정 D4). 위 "먼저 할 일" 7·8 | `scripts/check-type-fixtures.ts`, `scripts/check-typecheck-inputs.ts`, `tests/fixtures/typecheck/`, `package.json`, `config/ci/gates.json` | `bf485f44` |
|
||||
| [계약] **BREAKING** | 루트 등록부 `config/repository-layout.json`이 생겼다. 루트 경로 목록을 쓰던 7곳(복사 대상, 비밀값 검사 범위, 공급망 시험, 이력 문서 검사, 규모 입력, vite 입력, TS 전용 규칙)이 등록부의 집합을 고른다. `schemas/`·수동 a11y 기록·hosting 응답 fixture를 옮겼다. 위 "먼저 할 일" 9~11 | `config/repository-layout.json`, `scripts/lib/repository-layout.ts`, `config/schemas/`, `docs/accessibility/route-reviews/`, `tests/fixtures/hosting/` | `79dc945a` |
|
||||
| [계약] | 저장소 배치 규칙 R1~R10을 매뉴얼 03 E절에 적고, 기계로 볼 수 있는 것을 게이트에 넣었다: R1·R2·R7(파일)·R9 `tests/unit/repository-layout.test.ts`, R3 `tests/unit/tracked-artifacts.test.ts`, R4·R5 `tests/unit/example-feature-rules.test.ts`(이상 FE-GATE-005), R6·R7(문서) `verify:documentation`(FE-GATE-017, 산출물에 `layoutRuleViolations`), R8 FE-GATE-003 | `docs/manual/03-outside-feature-folder.md`, `scripts/verify-documentation-readiness.ts`, `scripts/contracts/release-artifacts.ts` | `e902e657` |
|
||||
|
||||
### 그 밖의 수정
|
||||
|
||||
- 정리 3단계에서 문서가 가리키던 옛 명령·경로(`check:types:fixture:*`, `check:types:recipes`, a11y 기록과 스키마 경로)를 새 이름으로 바꿨다 (`bf485f44`, `79dc945a`).
|
||||
- 정리 1단계: 읽는 곳 없는 산출물 13개를 지우고 `artifacts/`를 폴더째 무시한다(`85f941c4`). 아무도 읽지 않는 `config/schemas/` JSON Schema 4개를 지웠다(`0805910c`). 루트 `tasks/`와 `.superpowers/` 기록을 `docs/history/`로 옮겼다(`429b8d88`). nginx 설정 예시를 지우고 호스트가 지킬 조건만 남겼다(`121e1125`).
|
||||
- `/examples/ui`·`/examples/states`를 열던 e2e(반응형, 스크롤 복원, 타이포그래피, 건너뛰기 링크)는 홈과 `/examples/platform`으로 옮겼다 (`e7210c71`).
|
||||
- 매뉴얼(`docs/manual/`)의 예제 칸은 생성기 출력 경로와 매뉴얼 안 코드 조각을 가리킨다. 코드 조각 일곱 개(problem details 백엔드의 분류와 매핑, 도메인 모델, 검색값 읽기, 실패 행동, 403 페이지 시험)는 `tests/unit/manual-code-blocks.test.ts`가 생성 기능 위에서 타입 검사·lint·아키텍처 검사·동작 시험을 돌린다. problem details 예는 소유자 결정대로 02 결정표 4절에 있다 (`01cac930`).
|
||||
@@ -92,6 +102,8 @@
|
||||
### 알려진 제한
|
||||
|
||||
- 두 다운스트림에 시험 병합을 하지 않아 충돌 수를 모른다(S4 가정 F4).
|
||||
- R2 검사는 등록부를 쓰는 7곳만 본다. 그 밖에 루트 이름 둘 이상을 담은 문자열 배열이 약 20곳 남았다(예: `tests/e2e/support/fixture-builds.ts`의 복사 제외 목록, `scripts/check-test-evidence.ts`의 playwright 설정 목록). 뜻이 다른 목록이라 이번에 옮기지 않았다.
|
||||
- R5는 문자열 검색이라 샘플 ID나 라우트 경로를 조립해 쓰는 시험은 놓친다.
|
||||
- 성능 lab(FE-GATE-026)의 기능 라우트 측정(`featureRouteInteractionMs`)은 템플릿에 공개 기능 라우트가 없어 `measured: false`다. 제품 기능이 생기면 잰다.
|
||||
- `TEMPLATE_FIXTURE` 출처와 `REFERENCE_EXTERNAL_BEARER` 별칭이 플랫폼 코드에 남았다. 쓰는 기능이 없다.
|
||||
- visual 골든의 픽셀 비교는 색 허용치(`threshold` 0.2)를 넘지 않는 미세한 토큰 변경(예: 어두운 테마 `--color-danger` red-500 → red-600)을 잡지 못한다. 옛 골든도 같았다.
|
||||
|
||||
@@ -304,7 +304,7 @@ Two gates intentionally need external evidence:
|
||||
|
||||
- `review:a11y-manual` (release gate FE-GATE-028) needs a signed human
|
||||
keyboard/focus/screen-reader review of every registered route, one record
|
||||
per route at `artifacts/tests/a11y-manual/<ROUTE_ID>.md`. The routes are
|
||||
per route at `docs/accessibility/route-reviews/<ROUTE_ID>.md`. The routes are
|
||||
`ROUTE_REGISTRY`; `verify:documentation` fails, naming the route ID, when a
|
||||
registered route has no record. The merge gate FE-GATE-009 runs only
|
||||
`review:a11y-manual -- --format-only`, which checks that every route record
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
{
|
||||
"schemaVersion": 1,
|
||||
"owner": "DongHyeonka",
|
||||
"reason": "2026-11-07 소유자 결정: 템플릿 샘플 삭제. 참조 기능 시험 명령과 그 산출물, 지운 라우트의 수동 a11y 기록 산출물 4개를 뺀다",
|
||||
"reason": "2026-11-07 소유자 결정: 정리 3단계(design-docs repo-structure/README.md 3.4절). 음성 타입 fixture 명령 23개를 실행기 하나로 합치고, 수동 a11y 기록을 docs/accessibility/route-reviews로, JSON Schema를 config/schemas로 옮긴다",
|
||||
"gates": 27,
|
||||
"commands": 99,
|
||||
"commandReferences": 103,
|
||||
"commands": 76,
|
||||
"commandReferences": 80,
|
||||
"artifacts": 105,
|
||||
"stages": 5,
|
||||
"gateShapeSha256": "df584fba26f8448c6a77638351c6906ed91869da82e20f12ac71ea7b2037c989"
|
||||
"gateShapeSha256": "5b2ded190e5c1cbfc31f0d8c90fa358defe87850d99dc4db5439426b9ed72a90"
|
||||
}
|
||||
|
||||
+12
-194
@@ -23,169 +23,10 @@
|
||||
"expect": "pass"
|
||||
},
|
||||
{
|
||||
"id": "check-types-recipes",
|
||||
"script": "check:types:recipes",
|
||||
"id": "check-types-fixtures",
|
||||
"script": "check:types:fixtures",
|
||||
"expect": "pass"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture",
|
||||
"script": "check:types:fixture",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-ts-port",
|
||||
"script": "check:types:fixture:ts-port",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-ts-result",
|
||||
"script": "check:types:fixture:ts-result",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2339:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-application-output",
|
||||
"script": "check:types:fixture:application-output",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-application-input",
|
||||
"script": "check:types:fixture:application-input",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2739:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-feature-input",
|
||||
"script": "check:types:fixture:feature-input",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2345:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-failure-kind",
|
||||
"script": "check:types:fixture:failure-kind",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-reference-operation",
|
||||
"script": "check:types:fixture:reference-operation",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2741:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-http-operation-input",
|
||||
"script": "check:types:fixture:http-operation-input",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2353:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-http-wire-mapper",
|
||||
"script": "check:types:fixture:http-wire-mapper",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-http-operation-id",
|
||||
"script": "check:types:fixture:http-operation-id",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2345:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-http-route-id",
|
||||
"script": "check:types:fixture:http-route-id",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-feature-contribution-input",
|
||||
"script": "check:types:fixture:feature-contribution-input",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-feature-capability-selection",
|
||||
"script": "check:types:fixture:feature-capability-selection",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2339:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-direct-feature-composition",
|
||||
"script": "check:types:fixture:direct-feature-composition",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2345:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-async-overlay",
|
||||
"script": "check:types:fixture:async-overlay",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2322:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-route-runtime",
|
||||
"script": "check:types:fixture:route-runtime",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2741:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-page-action",
|
||||
"script": "check:types:fixture:page-action",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS1360:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-icon-button",
|
||||
"script": "check:types:fixture:icon-button",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2741:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-i18n-key",
|
||||
"script": "check:types:fixture:i18n-key",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2345:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-i18n-params",
|
||||
"script": "check:types:fixture:i18n-params",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2554:"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-diagnostics",
|
||||
"script": "check:types:fixture:diagnostics",
|
||||
"expect": "pass"
|
||||
},
|
||||
{
|
||||
"id": "check-types-fixture-image-resolve-signal",
|
||||
"script": "check:types:fixture:image-resolve-signal",
|
||||
"expect": "fail",
|
||||
"expectedExitCode": 1,
|
||||
"expectedDiagnosticId": "error TS2741:"
|
||||
},
|
||||
{
|
||||
"id": "test-runtime-schema",
|
||||
"script": "test:runtime-schema",
|
||||
@@ -1144,14 +985,14 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"id": "artifact-artifacts-tests-a11y-manual-APP-HOME-md",
|
||||
"path": "artifacts/tests/a11y-manual/APP_HOME.md",
|
||||
"id": "artifact-docs-accessibility-route-reviews-APP-HOME-md",
|
||||
"path": "docs/accessibility/route-reviews/APP_HOME.md",
|
||||
"schemaId": "markdown",
|
||||
"production": "source-controlled"
|
||||
},
|
||||
{
|
||||
"id": "artifact-artifacts-tests-a11y-manual-NOT-FOUND-md",
|
||||
"path": "artifacts/tests/a11y-manual/NOT_FOUND.md",
|
||||
"id": "artifact-docs-accessibility-route-reviews-NOT-FOUND-md",
|
||||
"path": "docs/accessibility/route-reviews/NOT_FOUND.md",
|
||||
"schemaId": "markdown",
|
||||
"production": "source-controlled"
|
||||
},
|
||||
@@ -1755,30 +1596,7 @@
|
||||
"name": "typecheck",
|
||||
"commandIds": [
|
||||
"check-types",
|
||||
"check-types-recipes",
|
||||
"check-types-fixture",
|
||||
"check-types-fixture-ts-port",
|
||||
"check-types-fixture-ts-result",
|
||||
"check-types-fixture-application-output",
|
||||
"check-types-fixture-application-input",
|
||||
"check-types-fixture-feature-input",
|
||||
"check-types-fixture-failure-kind",
|
||||
"check-types-fixture-reference-operation",
|
||||
"check-types-fixture-http-operation-input",
|
||||
"check-types-fixture-http-wire-mapper",
|
||||
"check-types-fixture-http-operation-id",
|
||||
"check-types-fixture-http-route-id",
|
||||
"check-types-fixture-feature-contribution-input",
|
||||
"check-types-fixture-feature-capability-selection",
|
||||
"check-types-fixture-direct-feature-composition",
|
||||
"check-types-fixture-async-overlay",
|
||||
"check-types-fixture-route-runtime",
|
||||
"check-types-fixture-page-action",
|
||||
"check-types-fixture-icon-button",
|
||||
"check-types-fixture-i18n-key",
|
||||
"check-types-fixture-i18n-params",
|
||||
"check-types-fixture-diagnostics",
|
||||
"check-types-fixture-image-resolve-signal"
|
||||
"check-types-fixtures"
|
||||
],
|
||||
"logArtifactId": "artifact-artifacts-quality-check-types-txt",
|
||||
"evidenceArtifactIds": [
|
||||
@@ -2186,8 +2004,8 @@
|
||||
],
|
||||
"logArtifactId": "artifact-artifacts-quality-gates-FE-GATE-028-txt",
|
||||
"evidenceArtifactIds": [
|
||||
"artifact-artifacts-tests-a11y-manual-APP-HOME-md",
|
||||
"artifact-artifacts-tests-a11y-manual-NOT-FOUND-md",
|
||||
"artifact-docs-accessibility-route-reviews-APP-HOME-md",
|
||||
"artifact-docs-accessibility-route-reviews-NOT-FOUND-md",
|
||||
"artifact-artifacts-tests-a11y-manual-report-json"
|
||||
],
|
||||
"retentionClassId": "release-coherence"
|
||||
@@ -2423,6 +2241,9 @@
|
||||
"artifacts/security/supply-chain-coherence.json",
|
||||
"artifacts/security/supply-chain-verification.json",
|
||||
"artifacts/security/vulnerability-report.json",
|
||||
"config/schemas/artifacts/build-manifest.schema.json",
|
||||
"config/schemas/artifacts/dependency-inventory.schema.json",
|
||||
"config/schemas/artifacts/supply-chain-verification.schema.json",
|
||||
"config/security/dependency-baseline.approval.json",
|
||||
"config/security/dependency-baseline.json",
|
||||
"config/security/dependency-change-evidence.json",
|
||||
@@ -2430,9 +2251,6 @@
|
||||
"config/security/secret-scan-policy.json",
|
||||
"config/security/vulnerability-exceptions.json",
|
||||
"config/security/vulnerability-policy.json",
|
||||
"schemas/artifacts/build-manifest.schema.json",
|
||||
"schemas/artifacts/dependency-inventory.schema.json",
|
||||
"schemas/artifacts/supply-chain-verification.schema.json",
|
||||
"scripts/contracts/release-artifacts.ts",
|
||||
"scripts/create-release-candidate.ts",
|
||||
"scripts/generate-supply-chain.ts",
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"$schema": "../../schemas/config/frontend-capability-recipes.schema.json",
|
||||
"$schema": "../schemas/recipes/frontend-capability-recipes.schema.json",
|
||||
"schemaVersion": 1,
|
||||
"decisionId": "VD-10",
|
||||
"defaultStatus": "NOT_INSTALLED",
|
||||
|
||||
@@ -0,0 +1,325 @@
|
||||
{
|
||||
"schemaVersion": 1,
|
||||
"kinds": {
|
||||
"source": "코드와 시험. 계층과 도구가 읽는다",
|
||||
"tool-convention": "도구가 루트에서 이 이름으로 찾는 설정 파일·폴더",
|
||||
"gate-input": "게이트와 런타임이 읽는 기준 데이터",
|
||||
"document": "사람이 읽는 문서",
|
||||
"history": "끝난 라운드의 기록. 이력 폴더로 옮길 대상이다(R10)",
|
||||
"output": "실행 출력. 추적하는 것은 `.gitkeep`뿐이다(R3)"
|
||||
},
|
||||
"sets": {
|
||||
"fixture-copy": "제거·생성 drill과 사본 시험이 복사하는 것(scripts/lib/removal-fixture.ts)",
|
||||
"fixture-documents": "기능을 더하거나 지우는 drill이 문서까지 맞는지 보려고 더 복사하는 문서(scripts/lib/removal-fixture.ts)",
|
||||
"secret-scan": "비밀값 검사와 공급망 목록의 범위. config/security/secret-scan-policy.json의 trackedRoots가 이 집합과 같아야 한다",
|
||||
"history-free": "이력 문서를 읽으면 안 되는 코드(tests/unit/deletable-history-documents.test.ts)",
|
||||
"scale-source": "규모 증거에서 '지금 코드'를 정하는 입력(scripts/verify-extreme-scale.ts)",
|
||||
"vite-build": "vite build가 읽는 입력(scripts/lib/vite-build-inputs.ts)",
|
||||
"typescript-only": "JS 파일을 두면 안 되는 곳(scripts/check-architecture.ts)"
|
||||
},
|
||||
"entries": [
|
||||
{
|
||||
"path": ".claude",
|
||||
"kind": "tool-convention",
|
||||
"role": "Claude Code 설정·규칙·스킬·서브에이전트",
|
||||
"readBy": "Claude Code"
|
||||
},
|
||||
{
|
||||
"path": ".dependency-cruiser.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "import 규칙과 kernel 예외의 정본",
|
||||
"readBy": "scripts/check-architecture.ts (FE-GATE-010)",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source"]
|
||||
},
|
||||
{
|
||||
"path": ".env.example",
|
||||
"kind": "tool-convention",
|
||||
"role": "빌드 시점 공개 변수의 견본",
|
||||
"readBy": "Vite(VITE_*), 사람"
|
||||
},
|
||||
{
|
||||
"path": ".gitattributes",
|
||||
"kind": "tool-convention",
|
||||
"role": "git 병합 규칙(작업 장부 docs/ledger/estimates.jsonl을 union으로 합친다)",
|
||||
"readBy": "git"
|
||||
},
|
||||
{
|
||||
"path": ".gitea",
|
||||
"kind": "tool-convention",
|
||||
"role": "Gitea Actions workflow. config/ci/gates.json에서 생성한다",
|
||||
"readBy": "Gitea Actions, scripts/generate-ci-workflow.ts, check:ci (FE-GATE-010)",
|
||||
"sets": ["fixture-copy", "history-free"],
|
||||
"setPaths": {
|
||||
"secret-scan": [".gitea/workflows/quality-gates.yml"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": ".gitignore",
|
||||
"kind": "tool-convention",
|
||||
"role": "추적하지 않을 파일",
|
||||
"readBy": "git",
|
||||
"sets": ["fixture-copy"]
|
||||
},
|
||||
{
|
||||
"path": ".npmrc",
|
||||
"kind": "tool-convention",
|
||||
"role": "pnpm 설정",
|
||||
"readBy": "pnpm",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": ".nvmrc",
|
||||
"kind": "tool-convention",
|
||||
"role": "Node 버전",
|
||||
"readBy": "nvm, CI",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": ".storybook",
|
||||
"kind": "tool-convention",
|
||||
"role": "Storybook 설정. 갤러리와 visual 골든의 대상",
|
||||
"readBy": "storybook, build:storybook (FE-GATE-011)",
|
||||
"sets": ["fixture-copy", "secret-scan", "scale-source", "typescript-only"]
|
||||
},
|
||||
{
|
||||
"path": "AGENTS.md",
|
||||
"kind": "tool-convention",
|
||||
"role": "에이전트 진입 문서(꼭 지킬 것·지도·검증). docs/README.md 1절이 가리키는 현재 계약 문서",
|
||||
"readBy": "코딩 에이전트, verify:documentation (FE-GATE-017)",
|
||||
"sets": ["fixture-documents"]
|
||||
},
|
||||
{
|
||||
"path": "CHANGELOG.md",
|
||||
"kind": "document",
|
||||
"role": "버전별 변경과 다운스트림이 할 일",
|
||||
"readBy": "tests/unit/changelog-review-ids.test.ts, 사람",
|
||||
"sets": ["fixture-documents"]
|
||||
},
|
||||
{
|
||||
"path": "CLAUDE.md",
|
||||
"kind": "tool-convention",
|
||||
"role": "Claude Code 진입 문서",
|
||||
"readBy": "Claude Code"
|
||||
},
|
||||
{
|
||||
"path": "PRODUCT.md",
|
||||
"kind": "tool-convention",
|
||||
"role": "제품 맥락. 디자인 도구가 루트에서 찾는다",
|
||||
"readBy": "디자인 스킬"
|
||||
},
|
||||
{
|
||||
"path": "README.md",
|
||||
"kind": "document",
|
||||
"role": "시작·설정·검증",
|
||||
"readBy": "verify:documentation (FE-GATE-017), 사람",
|
||||
"sets": ["fixture-documents"]
|
||||
},
|
||||
{
|
||||
"path": "SPEC.md",
|
||||
"kind": "history",
|
||||
"role": "2026-09-25 라운드 요구사항. 문서 체계 작업(fe-b)이 이력 폴더로 옮기고 이 항목을 뺀다",
|
||||
"readBy": "사람"
|
||||
},
|
||||
{
|
||||
"path": "artifacts",
|
||||
"kind": "output",
|
||||
"role": "게이트와 시험의 실행 출력",
|
||||
"readBy": "scripts/run-ci-gate.ts, CI 업로드"
|
||||
},
|
||||
{
|
||||
"path": "config",
|
||||
"kind": "gate-input",
|
||||
"role": "게이트·런타임·보안·성능의 기준 데이터와 JSON Schema(config/schemas)",
|
||||
"readBy": "scripts/, tests/, src/",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source"]
|
||||
},
|
||||
{
|
||||
"path": "docs",
|
||||
"kind": "document",
|
||||
"role": "매뉴얼·설계·운영 문서와 수동 접근성 검토 기록",
|
||||
"readBy": "verify:documentation (FE-GATE-017), review:a11y-manual (FE-GATE-009·028)",
|
||||
"sets": ["fixture-documents"],
|
||||
"setPaths": {
|
||||
"fixture-copy": ["docs/accessibility/route-reviews"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "eslint.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "lint 규칙",
|
||||
"readBy": "eslint (FE-GATE-002)",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source"]
|
||||
},
|
||||
{
|
||||
"path": "index.html",
|
||||
"kind": "tool-convention",
|
||||
"role": "Vite 진입 HTML",
|
||||
"readBy": "Vite",
|
||||
"sets": ["fixture-copy", "secret-scan", "vite-build"]
|
||||
},
|
||||
{
|
||||
"path": "package.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "의존성과 package script",
|
||||
"readBy": "pnpm, 모든 게이트",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source", "vite-build"]
|
||||
},
|
||||
{
|
||||
"path": "playwright.capabilities.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "브라우저 capability 시험 설정",
|
||||
"readBy": "test:browser-capabilities (FE-GATE-008)",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": "playwright.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "e2e 설정(빌드 미리보기)",
|
||||
"readBy": "test:e2e (FE-GATE-008)",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free"]
|
||||
},
|
||||
{
|
||||
"path": "playwright.dev.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "dev 서버 대상 e2e 설정",
|
||||
"readBy": "test:e2e:dev",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": "playwright.storybook.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "Storybook 정적 빌드 시험 설정",
|
||||
"readBy": "test:storybook (FE-GATE-008)",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": "playwright.visual.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "visual 골든 설정",
|
||||
"readBy": "test:visual (FE-GATE-008)",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": "pnpm-lock.yaml",
|
||||
"kind": "tool-convention",
|
||||
"role": "잠금 파일",
|
||||
"readBy": "pnpm, 공급망 생성",
|
||||
"sets": ["fixture-copy", "secret-scan", "scale-source"]
|
||||
},
|
||||
{
|
||||
"path": "pnpm-workspace.yaml",
|
||||
"kind": "tool-convention",
|
||||
"role": "pnpm 11 설정",
|
||||
"readBy": "pnpm, scripts/lib/package-script-graph.ts",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": "public",
|
||||
"kind": "tool-convention",
|
||||
"role": "개발 서버가 서빙하는 런타임 문서",
|
||||
"readBy": "Vite",
|
||||
"sets": ["fixture-copy", "secret-scan", "vite-build"]
|
||||
},
|
||||
{
|
||||
"path": "recipes",
|
||||
"kind": "source",
|
||||
"role": "선택 기능 설치 원본. 기본 빌드에 들어가지 않는다",
|
||||
"readBy": "tsconfig.test.json, test:recipes (FE-GATE-007), check:optional-recipes (FE-GATE-012)",
|
||||
"optional": true,
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source", "typescript-only"]
|
||||
},
|
||||
{
|
||||
"path": "renovate.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "보안 업데이트 봇 설정",
|
||||
"readBy": "Renovate"
|
||||
},
|
||||
{
|
||||
"path": "scripts",
|
||||
"kind": "source",
|
||||
"role": "게이트·생성기·drill 스크립트",
|
||||
"readBy": "package.json scripts",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source", "typescript-only"],
|
||||
"setPaths": {
|
||||
"vite-build": ["scripts/lib/run-isolation.ts", "scripts/lib/vite-module-inventory.ts"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"path": "src",
|
||||
"kind": "source",
|
||||
"role": "앱 계층",
|
||||
"readBy": "빌드와 모든 게이트",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source", "vite-build", "typescript-only"]
|
||||
},
|
||||
{
|
||||
"path": "tests",
|
||||
"kind": "source",
|
||||
"role": "시험과 fixture",
|
||||
"readBy": "test:* scripts, playwright 설정",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source", "typescript-only"]
|
||||
},
|
||||
{
|
||||
"path": "tsconfig.app.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "src 타입 검사(DOM, Node 타입 없음)",
|
||||
"readBy": "check:types:app (FE-GATE-003), Vite",
|
||||
"sets": ["fixture-copy", "secret-scan", "scale-source", "vite-build"]
|
||||
},
|
||||
{
|
||||
"path": "tsconfig.base.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "공통 컴파일 옵션",
|
||||
"readBy": "다른 tsconfig의 extends",
|
||||
"sets": ["fixture-copy", "secret-scan", "vite-build"]
|
||||
},
|
||||
{
|
||||
"path": "tsconfig.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "편집기용 solution tsconfig(files 없음, references만)",
|
||||
"readBy": "편집기",
|
||||
"sets": ["fixture-copy", "secret-scan", "scale-source"]
|
||||
},
|
||||
{
|
||||
"path": "tsconfig.node.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "scripts·설정 파일 타입 검사(NodeNext)",
|
||||
"readBy": "check:types:node (FE-GATE-003)",
|
||||
"sets": ["fixture-copy", "secret-scan", "scale-source"]
|
||||
},
|
||||
{
|
||||
"path": "tsconfig.service-worker.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "Service Worker 타입 검사(WebWorker, DOM 없음)",
|
||||
"readBy": "check:types:service-worker (FE-GATE-003)",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": "tsconfig.test.json",
|
||||
"kind": "tool-convention",
|
||||
"role": "tests·recipes·시험 설정 파일 타입 검사",
|
||||
"readBy": "check:types:test (FE-GATE-003)",
|
||||
"sets": ["fixture-copy", "secret-scan", "scale-source"]
|
||||
},
|
||||
{
|
||||
"path": "vite.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "앱 빌드",
|
||||
"readBy": "Vite",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source", "vite-build"]
|
||||
},
|
||||
{
|
||||
"path": "vite.service-worker.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "Service Worker 빌드",
|
||||
"readBy": "scripts/build-frontend.ts",
|
||||
"sets": ["fixture-copy", "secret-scan"]
|
||||
},
|
||||
{
|
||||
"path": "vitest.config.ts",
|
||||
"kind": "tool-convention",
|
||||
"role": "단위·컴포넌트 시험 설정",
|
||||
"readBy": "scripts/run-vitest.ts",
|
||||
"sets": ["fixture-copy", "secret-scan", "history-free", "scale-source"]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -7,7 +7,6 @@
|
||||
"tests",
|
||||
"config",
|
||||
"public",
|
||||
"schemas",
|
||||
".storybook",
|
||||
".gitea/workflows/quality-gates.yml",
|
||||
".dependency-cruiser.json",
|
||||
@@ -22,10 +21,8 @@
|
||||
"tsconfig.app.json",
|
||||
"tsconfig.base.json",
|
||||
"tsconfig.node.json",
|
||||
"tsconfig.recipes.json",
|
||||
"tsconfig.service-worker.json",
|
||||
"tsconfig.test.json",
|
||||
"tsconfig.web-worker.json",
|
||||
"vite.config.ts",
|
||||
"vite.service-worker.config.ts",
|
||||
"vitest.config.ts",
|
||||
|
||||
+1
-1
@@ -61,7 +61,7 @@ checkout이 없거나 그 커밋이 없으면 실패 대신 확인하지 못한
|
||||
| 파일 | 읽는 명령 |
|
||||
|---|---|
|
||||
| 이 파일, `architecture/review-ledger.json`, `architecture/review-evidence.md` | `verify:documentation` (FE-GATE-017) |
|
||||
| repo 루트의 `artifacts/tests/a11y-manual/` 라우트별 기록 | `verify:documentation` (FE-GATE-017), `review:a11y-manual` (FE-GATE-009, FE-GATE-028) |
|
||||
| `docs/accessibility/route-reviews/` 라우트별 기록 | `verify:documentation` (FE-GATE-017), `review:a11y-manual` (FE-GATE-009, FE-GATE-028) |
|
||||
| `reviews/adapters/INVENTORY.md` | `check:adapter-inventory` (FE-GATE-010) |
|
||||
| `operations/adapter-remediation-ledger.md`, `operations/adapter-remediation-dispositions.json` | `check:remediation-ledger` (게이트 밖. 이유는 `config/ci/ungated-scripts.json`) |
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
# Manual accessibility review checklist
|
||||
|
||||
Automated axe checks do not establish WCAG conformance. A human reviewer must
|
||||
review every route record in `artifacts/tests/a11y-manual/` against one
|
||||
review every route record in `docs/accessibility/route-reviews/` against one
|
||||
release candidate and sign them. The required scope is the route registry
|
||||
(`ROUTE_REGISTRY` in `src/features/installed-feature-contracts.ts`): one
|
||||
record per route, named `<ROUTE_ID>.md`. Copy the template fields exactly; the
|
||||
|
||||
@@ -15,7 +15,7 @@ production readiness를 뜻하지 않는다.
|
||||
| 항목 | 경로 | production 포함 |
|
||||
| --- | --- | --- |
|
||||
| 선택/금지/예산 SSOT | `config/recipes/frontend-capability-recipes.json` | 정책만 |
|
||||
| catalog JSON schema | `schemas/config/frontend-capability-recipes.schema.json` | 아니오 |
|
||||
| catalog JSON schema | `config/schemas/recipes/frontend-capability-recipes.schema.json` | 아니오 |
|
||||
| TypeScript port | `recipes/frontend-capabilities/contracts.ts` | 아니오 |
|
||||
| fake/unavailable | `recipes/frontend-capabilities/fake-adapters.ts` | 아니오 |
|
||||
| contract test | `tests/recipes/optional-capability-contracts.test.ts` | 아니오 |
|
||||
@@ -330,7 +330,7 @@ Web Push를 함께 설치하지 않는다.
|
||||
## 6. 검증 명령
|
||||
|
||||
```bash
|
||||
corepack pnpm check:types:recipes
|
||||
corepack pnpm check:types:test
|
||||
corepack pnpm test:recipes
|
||||
corepack pnpm test:browser-capabilities
|
||||
corepack pnpm build
|
||||
|
||||
@@ -222,7 +222,7 @@ Files outside the feature directory. Everything else a feature needs is in
|
||||
| `config/scale/feature-shape-ceilings.json` `initialJavascript` (tracked) | every added or removed feature, and every template change that moves the initial JavaScript: `node scripts/scale/measure-feature-shape-growth.ts --initial-baseline --write`. Commit it with the change; on a merge conflict run the command again | `test:unit` (the feature-shape growth test compares it with a build) |
|
||||
| `src/contexts/<context>/context-module.ts` | the feature needs a new context | `generate:feature-index`: `Feature <id> belongs to undeclared context <context>` |
|
||||
| `src/contexts/<context>/context-layout.tsx` | the context needs its own frame instead of `AppShell` (see "Product home and layouts" below) | nothing: without it the context renders in `AppShell` |
|
||||
| `artifacts/tests/a11y-manual/<ROUTE_ID>.md` | every route the feature adds. Copy a record and reset it to `Status: pending-manual-review` | `test:unit` (`tests/unit/manual-a11y-evidence.test.ts`), `verify:documentation` (names the route IDs) and FE-GATE-009 (`review:a11y-manual -- --format-only`). FE-GATE-028 requires the signed review at release |
|
||||
| `docs/accessibility/route-reviews/<ROUTE_ID>.md` | every route the feature adds. Copy a record and reset it to `Status: pending-manual-review` | `test:unit` (`tests/unit/manual-a11y-evidence.test.ts`), `verify:documentation` (names the route IDs) and FE-GATE-009 (`review:a11y-manual -- --format-only`). FE-GATE-028 requires the signed review at release |
|
||||
| `tests/e2e/accessibility.spec.ts` | never per feature (1103/16-03): it fills every path parameter with one value and answers each API request from the installed descriptor, a list read with an empty list in its `responseEnvelope` frame. Edit it only for a protected page that sends something other than an installed GET before it renders | `test:a11y` (FE-GATE-009): a request no installed GET declares fails the route; so does an alert box (`role="alert"`) on a page that read only lists |
|
||||
| `src/features/product-capabilities.ts` (product-owned) | `needs` names a capability the template does not build: type it in `ProductFeaturePlatformCapabilities`. `FeaturePlatformCapabilities` extends it, so the app, scripts and tests typecheck programs all see the key (an augmentation inside `product-composition.ts` is not seen by the scripts' program) | `check:types`: `Type '"<capability>"' is not assignable to type 'keyof FeaturePlatformCapabilities'` in the feature |
|
||||
| `src/bootstrap/product-composition.ts` (product-owned) | `needs` names a capability the template does not build: return the capability here, typed in `product-capabilities.ts`. `indexedDb` is built as in `recipes/frontend-capabilities/indexeddb-feature-capability.ts`. Credentials for a product auth profile are returned here too. A product that owns the session (a BFF's httpOnly cookie) returns its session owner from `composeProductSessionOwner` instead of installing it on the host global before boot | `check:types`; at runtime `feature <id> needs <capability>, which the host did not provide`. Without the session owner, `AUTH_MODE: "external"` boots with the session `integration-failed` |
|
||||
|
||||
@@ -369,7 +369,7 @@ projectRequest: (input) => Object.freeze({
|
||||
- application이 React·어댑터·presentation을 import하면 `check:architecture`가 `feature-application-does-not-know-runtime`으로 막는다.
|
||||
- 보강 키와 조립 기여의 `featureId`가 다르면 조립이 실패한다.
|
||||
- 메시지: `feature adapter contribution <id> installed an input for <other>`
|
||||
- input 모양이 보강 타입과 다르면 `check:types`(FE-GATE-003)가 막는다. 음성 fixture `check:types:fixture:feature-input`도 같은 게이트에서 돈다.
|
||||
- input 모양이 보강 타입과 다르면 `check:types`(FE-GATE-003)가 막는다. 음성 fixture `tests/fixtures/typecheck/invalid-feature-input.ts`도 같은 게이트의 `check:types:fixtures`에서 돈다.
|
||||
- **못 잡음**: telemetry `kind` 중복. 유일성 검사가 없다. 접두어로 피한다.
|
||||
|
||||
④ **쓸 스킬**: `clean-architecture`, `codebase-design`
|
||||
@@ -408,7 +408,7 @@ projectRequest: (input) => Object.freeze({
|
||||
- presentation이 기능 `adapters/`를 import하면 `feature-presentation-does-not-know-outbound-adapters`로 막는다.
|
||||
- adapters가 presentation을 import하면 `feature-adapters-do-not-know-presentation`으로 막는다.
|
||||
- 기능 루트 파일(`feature-module.ts` 등)이나 계층이 아닌 폴더(`support/` 등)의 파일이 `src/adapters`에 닿으면 `feature-and-app-roots-do-not-reach-adapters`로 막는다. 기능 안에서 `src/adapters`에 닿을 수 있는 곳은 `adapters/` 폴더뿐이다.
|
||||
- operation ID·route ID·입력 타입을 틀리면 `check:types`가 막는다. 음성 fixture: `check:types:fixture:http-operation-id`, `check:types:fixture:http-route-id`, `check:types:fixture:http-operation-input`.
|
||||
- operation ID·route ID·입력 타입을 틀리면 `check:types`가 막는다. 음성 fixture: `tests/fixtures/typecheck/invalid-http-operation-id.ts`, `tests/fixtures/typecheck/invalid-http-route-id.ts`, `tests/fixtures/typecheck/invalid-http-operation-input.ts`(`check:types:fixtures`).
|
||||
- 호스트가 주지 않는 capability를 `needs`에 적으면 조립이 실패한다.
|
||||
- 메시지: `feature <id> needs <capability>, which the host did not provide`
|
||||
- operation을 계약에 두고 기능 `adapters/`·`application/`에서 쓰지 않으면 `check:registries`(FE-GATE-010)가 실패한다.
|
||||
@@ -430,7 +430,7 @@ projectRequest: (input) => Object.freeze({
|
||||
- `presentation/<base>-routes.ts`: 링크용 URL 함수. route ID를 받아 `buildRouteUrl`(`src/presentation/routes/route-codecs.ts`)로 경로를 채운다.
|
||||
- 문구 `route.<ROUTE_ID>.title`, `route.<ROUTE_ID>.navigation` (ko-KR, en-US). 화면의 문서 제목과 메뉴 이름은 이 문구다.
|
||||
- 계약 `routes`의 `title`·`navigationLabel`은 화면이 읽지 않는다. FE-REG-ROUTE 기준선 행과 lab 측정(`scripts/test-performance.ts`, 플랫폼 라우트만)이 읽는다. 생성 명령은 문구와 같은 값을 넣는다. 값을 바꾸면 `check:registries`가 behavior-change로 기록한다.
|
||||
- 기능 폴더 밖: `artifacts/tests/a11y-manual/<ROUTE_ID>.md`(pending 기록). 생성 명령이 만든다.
|
||||
- 기능 폴더 밖: `docs/accessibility/route-reviews/<ROUTE_ID>.md`(pending 기록). 생성 명령이 만든다.
|
||||
|
||||
① **정할 것**
|
||||
|
||||
@@ -506,7 +506,7 @@ export function useInvoiceListFilters(): InvoiceListSearch {
|
||||
- `context-routes.ts`의 handle이 계약에 없는 route ID를 가리키면 context 적재가 거부한다.
|
||||
- 메시지: `Route handle <ROUTE_ID> loaded by context <context> is not a contract route of its features (...)`
|
||||
- 라우트별 a11y 기록이 없으면 세 곳이 잡는다.
|
||||
- `verify:documentation`(FE-GATE-017): `artifacts/tests/a11y-manual/ has no record for route IDs: <ids>`
|
||||
- `verify:documentation`(FE-GATE-017): `docs/accessibility/route-reviews/ has no record for route IDs: <ids>`
|
||||
- `review:a11y-manual -- --format-only`(FE-GATE-009): `missing record`
|
||||
- `test:unit`의 `tests/unit/manual-a11y-evidence.test.ts`
|
||||
- en-US 문구 키가 ko-KR과 다르면 `check:i18n`(FE-GATE-010)이 `en-US catalog keys do not match ko-KR`로 실패한다.
|
||||
@@ -790,7 +790,7 @@ corepack pnpm test:sample-removal -- --feature=invoice-feature
|
||||
- 템플릿 테스트가 예시 ID(`invoice-feature` 등)를 데이터로 쓰는 것은 잔여로 세지 않는다(1105/16-04). 그래서 매뉴얼 예시 이름으로 만든 기능도 이 단계를 통과한다.
|
||||
- spec 본문은 이름 단위로 찾는다(1106/16-01). 적힌 그대로(대소문자 구분) 찾고, 앞뒤에 `[A-Za-z0-9_-]`가 붙으면 다른 이름이다. `test.describe("invoice-feature", …)`는 잔여이고, `product-feature`를 지울 때 `generate-product-feature-index.ts`처럼 더 긴 이름 안에 든 것은 잔여가 아니다. spec은 `test:all`(vitest)도 드릴의 다른 단계도 돌리지 않으므로 이 검사가 아니면 다음 CI의 브라우저 게이트에서야 실패한다.
|
||||
- `-`가 없는 한 단어 ID·폴더 이름(`messages`, `status`)은 spec 본문에서 찾지 않는다. 템플릿 spec이 그 단어를 평범하게 쓰므로(`status: 200`, `getByRole("status")`) 찾으면 템플릿 spec이 잔여로 나온다.
|
||||
- **못 잡음**: 기능을 가리키지 않는 폴더 밖 파일. 예: route ID나 URL만 적은 e2e spec, 한 단어 ID만 본문에 적은 spec, `artifacts/tests/a11y-manual/<ROUTE_ID>.md`. 기능 전용 spec은 [03 문서](03-outside-feature-folder.md)의 목록대로 손으로 지운다. vitest 테스트(`*.test.ts`) 안에서 기능 ID를 글자로만 적은 것도 잔여로 세지 않는다. 그 테스트가 지운 기능에 기대면 같은 드릴의 `test:all`이 실패한다. 드릴은 `src`와 `tests`만 찾고, a11y 기록은 남아도 검사가 실패하지 않는다.
|
||||
- **못 잡음**: 기능을 가리키지 않는 폴더 밖 파일. 예: route ID나 URL만 적은 e2e spec, 한 단어 ID만 본문에 적은 spec, `docs/accessibility/route-reviews/<ROUTE_ID>.md`. 기능 전용 spec은 [03 문서](03-outside-feature-folder.md)의 목록대로 손으로 지운다. vitest 테스트(`*.test.ts`) 안에서 기능 ID를 글자로만 적은 것도 잔여로 세지 않는다. 그 테스트가 지운 기능에 기대면 같은 드릴의 `test:all`이 실패한다. 드릴은 `src`와 `tests`만 찾고, a11y 기록은 남아도 검사가 실패하지 않는다.
|
||||
|
||||
④ **쓸 스킬**: `documentation-and-adrs`, `deprecation-and-migration`
|
||||
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
- `src/contexts/<context>/context-module.ts`
|
||||
- 새 context일 때만 만든다. `--context`를 주면 만들지 않는다.
|
||||
- 왜 밖인가: context는 여러 기능이 함께 쓰는 소속 선언이다. 기능 하나가 갖지 않는다.
|
||||
- `artifacts/tests/a11y-manual/<ROUTE_ID>.md`
|
||||
- `docs/accessibility/route-reviews/<ROUTE_ID>.md`
|
||||
- 라우트마다 하나. `Status: pending-manual-review`로 만든다.
|
||||
- 왜 밖인가: 수동 접근성 검토 기록은 라우트 단위로 한 폴더에 모은다. 릴리스 검토자가 한 곳에서 서명한다.
|
||||
- pending 기록은 merge 게이트를 통과하고 릴리스 게이트를 넘지 못한다(원칙 7).
|
||||
@@ -62,7 +62,7 @@ create:feature가 pending 기록을 만든다
|
||||
|
||||
1. 릴리스 후보 하나를 띄운다.
|
||||
2. `docs/accessibility/manual-checklist.md`의 M1~M7과 스크린 리더 항목을 그 라우트에서 확인한다.
|
||||
3. `artifacts/tests/a11y-manual/<ROUTE_ID>.md`를 채운다.
|
||||
3. `docs/accessibility/route-reviews/<ROUTE_ID>.md`를 채운다.
|
||||
- `Status: reviewed`, `Release ID`, `Reviewer`, `Reviewed at`, `Signature`, `Attestation: accepted`
|
||||
- 항목마다 `pass` 또는 `not-applicable (<구체적 이유>)`
|
||||
4. 모든 라우트 기록의 `Release ID`가 같아야 한다.
|
||||
@@ -184,6 +184,28 @@ src/features/product-capabilities.ts (SERVICE_WORKER = ACTIVE)
|
||||
- 템플릿이 아직 연결하지 않은 것: 활성화 화면(`onUpdateWaiting`·`requestActivation()`). 확인할 것 목록은 `docs/architecture/optional-adapter-recipes.md`의 "Service Worker를 켤 때 확인할 것"에 있다.
|
||||
- realtime·Web Worker·오프라인 명령을 고르면 조립이 `Selected optional capabilities have no runtime to start them`로 거절한다. 템플릿 조립에 아직 그 런타임이 없다.
|
||||
|
||||
### Web Worker를 들일 때 tsconfig 더하기
|
||||
|
||||
템플릿에는 Web Worker 코드가 없다. 그래서 Worker용 tsconfig도 없다. 빈 tsconfig는 0파일을 검사하고 통과한다(아래 E절 R8). 2026-11-08에 지웠다. Worker 코드를 처음 넣는 변경에서 아래를 함께 한다.
|
||||
|
||||
1. Worker 코드를 `src/adapters/web-worker/`에 둔다. 그 폴더의 `index.ts`가 배럴이다.
|
||||
2. 루트에 `tsconfig.web-worker.json`을 만든다. lib가 `WebWorker`이고 DOM이 없어서, Worker 코드가 `document`·`window`를 쓰면 실패한다. `tsconfig.service-worker.json`과 같은 이유다.
|
||||
|
||||
```json
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"compilerOptions": { "lib": ["ES2022", "WebWorker"], "types": [], "skipLibCheck": false },
|
||||
"include": ["src/adapters/web-worker"],
|
||||
"exclude": ["src/adapters/web-worker/index.ts"]
|
||||
}
|
||||
```
|
||||
|
||||
3. Worker 진입 파일을 `tsconfig.app.json`의 `exclude`에 더한다. 배럴처럼 페이지가 import하는 파일은 app 프로그램에 남긴다.
|
||||
4. `tsconfig.json`의 `references`에 `{ "path": "./tsconfig.web-worker.json" }`을 더한다. 편집기가 Worker 파일에 이 설정을 쓴다.
|
||||
5. `package.json`에 `"check:types:web-worker": "tsc --project tsconfig.web-worker.json"`을 더하고 `check:types` 사슬에 잇는다. 사슬 끝의 `node scripts/check-typecheck-inputs.ts`가 이 tsconfig의 입력이 0개면 실패시킨다.
|
||||
6. `config/repository-layout.json`에 `tsconfig.web-worker.json` 항목을 더한다(E절 R1). `sets`는 `tsconfig.service-worker.json`과 같게 `fixture-copy`·`secret-scan`이다. `config/security/secret-scan-policy.json`의 `trackedRoots`에도 같은 이름을 더한다(R2).
|
||||
7. `scripts/verify-documentation-readiness.ts`의 `NOT_CREATED`에서 `src/adapters/web-worker`를 뺀다.
|
||||
|
||||
---
|
||||
|
||||
## D. 고치지 않는다
|
||||
@@ -199,13 +221,37 @@ src/features/product-capabilities.ts (SERVICE_WORKER = ACTIVE)
|
||||
|
||||
---
|
||||
|
||||
## E. 저장소 배치 규칙 (R1~R10)
|
||||
|
||||
기능 밖의 루트 폴더·설정·검사를 더하거나 옮길 때 지킨다. 2026-11-07 소유자 지적(샘플이 남아 있음, 역할이 겹치는 루트 폴더, 0파일 검사, 문서 속 인프라 설정)이 다시 나오지 않게 하는 규칙이다. 설계와 근거는 design-docs `repo-structure/04-frontend-layout.md` 11절이다.
|
||||
|
||||
| ID | 규칙 | 검사 |
|
||||
| --- | --- | --- |
|
||||
| R1 | 루트 항목은 모두 `config/repository-layout.json`에 있다. 항목마다 종류(source·tool-convention·gate-input·document·history·output), 역할, 읽는 곳을 적는다 | `tests/unit/repository-layout.test.ts`(FE-GATE-005). 등록부에 없는 루트 항목이 추적되면 실패 |
|
||||
| R2 | 루트 경로 목록은 등록부의 이름 붙은 집합(`sets`, 하위 경로는 `setPaths`)에서만 고른다. 목록을 코드에 새로 적지 않는다. JSON 정책 파일(`config/security/secret-scan-policy.json`)은 그 집합의 사본을 갖고 시험이 같은지 본다 | 같은 시험. 목록을 쓰던 곳이 `scripts/lib/repository-layout.ts`를 import하는지, 루트 이름 두 개 이상의 문자열 배열이 없는지 |
|
||||
| R3 | 추적 파일은 읽는 곳이 있다. `artifacts/`는 출력 전용이라 `.gitkeep`만 추적한다. 사람이 쓴 기록은 `docs/` 아래에 둔다(수동 a11y 기록은 `docs/accessibility/route-reviews/`) | `tests/unit/tracked-artifacts.test.ts`(FE-GATE-005). `config/` 아래 고아 JSON은 리뷰가 본다 |
|
||||
| R4 | 템플릿이나 제품이 넣은 샘플 기능은 `scripts/lib/removable-template-features.ts` 목록에 있고, 복사본에서 지우고 빌드·시험하는 drill로 증명한다. 문서 검사만으로는 안 된다 | `tests/unit/example-feature-rules.test.ts`(FE-GATE-005). FE-GATE-020이 `test:sample-removal`을 목록 전체로 도는지 |
|
||||
| R5 | 게이트의 검사 대상(visual 골든, e2e 라우트, 게이트 증거 목록, 규모 측정)은 플랫폼 화면·시험 fixture·생성기 출력이다. 지울 샘플 기능이 아니다 | 같은 시험. 샘플의 기능 ID·라우트가 visual·e2e의 `goto`, `config/ci/gates.json` 산출물 경로, `config/scale/`에 나오면 실패 |
|
||||
| R6 | 매뉴얼의 예제 위치는 `create:feature` 출력이나 매뉴얼 안 코드 조각을 가리킨다. 지울 샘플 기능의 경로를 가리키지 않는다 | `verify:documentation`(FE-GATE-017). `docs/manual/`에 목록 샘플의 경로가 나오면 실패 |
|
||||
| R7 | 이 repo에 둘 수 있는 실행 환경 파일은 개발 의존 서비스용 compose와 개발 Dockerfile뿐이다. nginx·Kubernetes·Helm·Terraform 설정은 인프라 repo에 두고 링크한다. 호스트에 요구하는 것은 계약(`config/hosting/`)과 검사(FE-GATE-019)로 둔다 | 파일: `tests/unit/repository-layout.test.ts`(FE-GATE-005). 문서: `verify:documentation`(FE-GATE-017)이 현재 문서의 ```` ```nginx ````·```` ```hcl ```` 블록과 `kind: Deployment` 같은 매니페스트 줄을 막는다. 이력 폴더(`docs/history/`, `docs/reviews/`, `docs/superpowers/`)는 기록이라 보지 않는다 |
|
||||
| R8 | 검사 대상이 0개인 게이트 명령은 실패하거나 SKIP을 출력한다. 통과로 보이면 안 된다 | FE-GATE-003: `scripts/check-typecheck-inputs.ts`(package script가 tsc에 넘기는 tsconfig마다 이 repo 파일이 1개 이상), `scripts/check-type-fixtures.ts`(fixture 0개면 실패) |
|
||||
| R9 | tsconfig는 lib·types·모듈 해석 중 하나가 다를 때만 새로 만든다. 옵션이 같고 파일만 다르면 실행기 하나로 돈다(예: 음성 타입 fixture는 `check:types:fixtures` 하나) | `tests/unit/repository-layout.test.ts`(FE-GATE-005). 옵션이 같은 tsconfig 쌍이 있으면 실패 |
|
||||
| R10 | 이력 문서(끝난 라운드의 계획·작업 목록·보고)는 루트나 숨김 폴더에 두지 않고 이력 폴더 한 곳에 둔다. 정본으로 쓰이는 부분은 이력에 두지 않는다 | 루트 `*.md`는 R1 등록부에 종류와 함께 있어야 한다. "정본으로 쓰이는가"는 리뷰가 본다 |
|
||||
|
||||
루트 항목을 더하거나 옮길 때의 순서:
|
||||
|
||||
1. `config/repository-layout.json`에 항목을 더하거나 고친다. 종류·역할·읽는 곳을 적는다(R1).
|
||||
2. 그 항목이 들어갈 집합을 `sets`(항목 전체)나 `setPaths`(항목 안 경로)에 적는다. 집합의 뜻은 파일 머리의 `sets` 설명에 있다(R2).
|
||||
3. `secret-scan` 집합을 바꿨으면 `config/security/secret-scan-policy.json`의 `trackedRoots`도 같게 고친다.
|
||||
4. 새 tsconfig라면 R9를 먼저 본다. 다른 tsconfig와 옵션이 같으면 만들지 않는다.
|
||||
|
||||
## 기능을 지울 때
|
||||
|
||||
`corepack pnpm test:sample-removal -- --feature=<id>`는 복사본에서 지워 보고 게이트를 돈다. 실제 저장소에서 지울 때는 아래를 함께 지운다.
|
||||
|
||||
- `src/features/<id>/`, `tests/features/<id>/`
|
||||
- 그 context의 마지막 기능이면 `src/contexts/<context>/`
|
||||
- `artifacts/tests/a11y-manual/<ROUTE_ID>.md` (라우트마다)
|
||||
- `docs/accessibility/route-reviews/<ROUTE_ID>.md` (라우트마다)
|
||||
- 남아도 검사는 실패하지 않는다. 검사는 등록된 라우트의 기록만 읽는다. 그래서 잊기 쉽다.
|
||||
- 기능 전용 `tests/e2e/` spec
|
||||
- `config/runtime/<profile>.json`의 `FEATURE_OVERRIDES` 키
|
||||
|
||||
@@ -81,7 +81,7 @@ corepack pnpm create:feature <id> [--context <context id>] [--with-create [--key
|
||||
기능 폴더 밖:
|
||||
|
||||
- `src/contexts/<base>-context/context-module.ts`: 새 context일 때만
|
||||
- `artifacts/tests/a11y-manual/<ROUTE_ID>.md`: 라우트마다 pending 기록
|
||||
- `docs/accessibility/route-reviews/<ROUTE_ID>.md`: 라우트마다 pending 기록
|
||||
|
||||
## 뼈대 모양
|
||||
|
||||
@@ -95,7 +95,7 @@ corepack pnpm create:feature <id> [--context <context id>] [--with-create [--key
|
||||
- 쿼리 1개: `LIST_STANDARD` profile.
|
||||
- 무효화 topic 1개, namespace 1개, edge 1개.
|
||||
- 빈 배열 응답은 공유 빈 상태 화면으로 그린다. `tests/e2e/accessibility.spec.ts`는 이 목록 조회에 빈 목록을 Envelope 모양으로 답하고, 경고 상자가 없는지 본 뒤 axe를 돌린다. 그래서 생성한 목록 라우트는 빈 상태 화면으로 검사된다.
|
||||
- `--with-create`의 상세 라우트는 자원 하나를 읽는다. 빈 목록으로 답할 수 없어 실패 화면에서만 axe를 돌린다. 그래서 `artifacts/tests/a11y.json`은 이 라우트를 통과(`scope`)로 세지 않고 `notChecked`에 이유와 함께 적는다. 화면 내용의 접근성은 수동 검토 기록(`artifacts/tests/a11y-manual/<ROUTE_ID>.md`)이 맡는다.
|
||||
- `--with-create`의 상세 라우트는 자원 하나를 읽는다. 빈 목록으로 답할 수 없어 실패 화면에서만 axe를 돌린다. 그래서 `artifacts/tests/a11y.json`은 이 라우트를 통과(`scope`)로 세지 않고 `notChecked`에 이유와 함께 적는다. 화면 내용의 접근성은 수동 검토 기록(`docs/accessibility/route-reviews/<ROUTE_ID>.md`)이 맡는다.
|
||||
|
||||
한도·마감 같은 숫자는 `scripts/create-feature.ts`의 템플릿이 정본이다.
|
||||
|
||||
@@ -119,7 +119,7 @@ create:feature: <id> in <context> (new context), route <ROUTE_ID> at <path>
|
||||
created <파일> ...
|
||||
|
||||
Next:
|
||||
1. Before a release, have a person review and sign artifacts/tests/a11y-manual/<ROUTE_ID>.md (FE-GATE-028). ...
|
||||
1. Before a release, have a person review and sign docs/accessibility/route-reviews/<ROUTE_ID>.md (FE-GATE-028). ...
|
||||
2. Run the merge gates: corepack pnpm ci:gate -- FE-GATE-<NNN> for each gate of the merge stage ...
|
||||
The feature's own tests: node scripts/run-vitest.ts run tests/features/<id> ...
|
||||
The registry baseline does not change: ...
|
||||
@@ -138,7 +138,7 @@ create:feature warning: no --package was given, so src/features/<id>/contracts/<
|
||||
생성한 기능을 지우려면 만든 것을 지우고 생성기를 다시 돌린다.
|
||||
|
||||
```bash
|
||||
rm -r src/features/<id> tests/features/<id> artifacts/tests/a11y-manual/<ROUTE_ID>.md
|
||||
rm -r src/features/<id> tests/features/<id> docs/accessibility/route-reviews/<ROUTE_ID>.md
|
||||
rm -r src/contexts/<base>-context # 새 context를 만들었을 때만
|
||||
corepack pnpm generate:feature-index
|
||||
node scripts/write-dev-release-manifest.ts # dev manifest에서 그 기능의 계약 패키지를 뺀다
|
||||
|
||||
@@ -175,8 +175,8 @@ lint / check:architecture / check:i18n → FE-GATE-002, FE-GATE-010
|
||||
|
||||
| 메시지 | 원인 | 고칠 곳 |
|
||||
|---|---|---|
|
||||
| `artifacts/tests/a11y-manual/ has no record for route IDs: <ids>` (`verify:documentation`) | 라우트의 a11y 기록 파일이 없다 | 기존 pending 기록을 복사해 제목과 `Route ID`를 바꾼다 |
|
||||
| `Manual accessibility record format is invalid:` 다음 `artifacts/tests/a11y-manual/<ROUTE_ID>.md: missing record` (FE-GATE-009) | 같은 원인 | 같은 곳 |
|
||||
| `docs/accessibility/route-reviews/ has no record for route IDs: <ids>` (`verify:documentation`) | 라우트의 a11y 기록 파일이 없다 | 기존 pending 기록을 복사해 제목과 `Route ID`를 바꾼다 |
|
||||
| `Manual accessibility record format is invalid:` 다음 `docs/accessibility/route-reviews/<ROUTE_ID>.md: missing record` (FE-GATE-009) | 같은 원인 | 같은 곳 |
|
||||
| `a11y.json not written:` 다음 `a11y: <ROUTE_ID> reads one resource (<operationId>) but has no failure-state record in artifacts/tests/a11y-data-state` (`test:a11y`, FE-GATE-009) | 라우트의 `paramsSchema`가 한 자원을 읽는 GET의 입력인데, 접근성 spec이 그 라우트를 실패 화면으로만 봤다는 기록이 없다(1106/11-01). spec이 기록 호출을 놓쳤거나, 그 라우트의 페이지가 그 GET을 부르지 않아 spec이 실패 화면을 보지 않았다. 앞의 경우 그대로면 `a11y.json`이 그 라우트를 통과로 센다 | 페이지가 그 GET을 부르면 `tests/e2e/accessibility.spec.ts`의 기록 호출(`recordA11yDataState`)을 본다. 이때 기능 파일은 고치지 않는다. 페이지가 그 GET을 부르지 않으면(예: `/things/:thingId/parts/new` 같은 하위 항목 작성 폼이 상세 GET과 같은 `ThingParams`를 쓴다) 그 라우트에 자기 `paramsSchema`를 따로 둔다. 기능의 라우트 계약과 `contracts/<base>-schema-metadata.ts`를 고친다 |
|
||||
| `Manual accessibility evidence is incomplete:` 다음 `<ROUTE_ID>: <failures>` (FE-GATE-028) | 서명하지 않은 기록 | [03 문서](../03-outside-feature-folder.md#수동-접근성-검토-서명) |
|
||||
| `release IDs do not match` (FE-GATE-028) | 라우트마다 다른 릴리스로 검토했다 | 같은 릴리스 후보로 다시 검토한다 |
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
- 형식: `qinv.` + 소문자·숫자 26자.
|
||||
- `scripts/create-feature.ts`의 `randomTopicSuffix`가 같은 형식으로 만든다.
|
||||
- 다른 기능의 값을 복사하지 않는다.
|
||||
- route ID는 `<BASE>_<화면>` 꼴로 짓는다(`INVOICE_DETAIL`). 라우트를 더하면 a11y 기록 파일도 더한다(`artifacts/tests/a11y-manual/<ROUTE_ID>.md`).
|
||||
- route ID는 `<BASE>_<화면>` 꼴로 짓는다(`INVOICE_DETAIL`). 라우트를 더하면 a11y 기록 파일도 더한다(`docs/accessibility/route-reviews/<ROUTE_ID>.md`).
|
||||
- 문구 키는 ko-KR과 en-US에 같은 키를 넣는다. `check:i18n`이 비교한다.
|
||||
|
||||
## 정본 위치
|
||||
|
||||
@@ -139,7 +139,7 @@ Rollout state starts at `NOT_STARTED`; documented-unimplemented items start at
|
||||
| BT-UP-05 | Refactor | `corepack pnpm exec vitest run tests/unit/resumable-upload-runtime.test.ts` | — | `NOT_PERFORMED` | characterization drift | **Attempted and reverted.** The five internal owners were extracted mechanically, but they require a shared-internals module for `RuntimeDependencies`, `ActiveResolution`, `ReconciliationResolution`, `FAILURE_CODES`, `RECOVERIES`, `reportProgress`, `observeTerminal` and ~40 further bindings to avoid an import cycle. Rather than risk the verified correctness work in this file, the extraction was reverted rather than half-landed. Behaviour and the public facade are unchanged; the file is still 2,239 lines. |
|
||||
| BT-UP-06 | Refactor | `corepack pnpm exec vitest run tests/unit/resumable-upload-runtime.test.ts` | `fix: drain resumable upload teardown` | `FIXED_NOT_RELEASED` | drain not quiescent | Red single-flight dispose case → green 18/18; `close()` closes admission and starts the same drain, `dispose()` aborts the active-operation registry and awaits real settlement before closing the checkpoint store |
|
||||
| BT-UP-07 | Documented gap (Web Locks matrix) | promotion evidence | — | `PROMOTION_BLOCKED` | n/a | — |
|
||||
| BT-IMG-01 | Type-contract change | `corepack pnpm check:types:test` fixture | `fix: complete presigned capability and upload transport contracts` | `FIXED_NOT_RELEASED` | caller compile break | `resolve()` now requires the lifetime signal; `tests/fixtures/typecheck/invalid-image-cdn-resolve-signal.ts` + `check:types:fixture:image-resolve-signal` fail as designed (2 errors), and all callers pass a signal |
|
||||
| BT-IMG-01 | Type-contract change | `corepack pnpm check:types:test` fixture | `fix: complete presigned capability and upload transport contracts` | `FIXED_NOT_RELEASED` | caller compile break | `resolve()` now requires the lifetime signal; `tests/fixtures/typecheck/invalid-image-cdn-resolve-signal.ts` (then its own script, merged into `check:types:fixtures` on 2026-11-08) fail as designed (2 errors), and all callers pass a signal |
|
||||
| BT-IMG-02 | Image probe | `corepack pnpm exec vitest run tests/unit/image-cdn-runtime.test.ts` | `fix: parse Cache-Control with quote awareness` | `FIXED_NOT_RELEASED` | Cache-Control parse rejection | Red unmatched-quote cases → green 25/25 |
|
||||
| BT-IMG-03 | Refactor | `corepack pnpm exec vitest run tests/unit/image-cdn-runtime.test.ts` | — | `NOT_PERFORMED` | characterization drift | **Not performed.** Same reasoning as BT-UP-05: a pure cohesion refactor of `image-cdn-runtime.ts` (1,340 lines) with no finding closure. `image-header-metadata.ts` is deliberately left intact per the review. |
|
||||
| BT-IMG-04 | Documented gap (descriptor provider) | promotion evidence | — | `PROMOTION_BLOCKED` | n/a | — |
|
||||
@@ -199,7 +199,7 @@ Captured after every correctness task landed.
|
||||
| `corepack pnpm test:unit` | 1 | 1585 passed / 19 failed tests; the 19 are the unchanged pre-existing `ci-artifact-contract` sandbox failures |
|
||||
| `corepack pnpm check:registries` | 0 | 11 registries PASS |
|
||||
| `corepack pnpm verify:documentation` | 0 | PASS_SCOPED |
|
||||
| `corepack pnpm check:types:fixture:image-resolve-signal` | 1 | **Expected non-zero.** Negative fixture proving `resolve()` now rejects a call without a lifetime signal (BT-IMG-01). |
|
||||
| 음성 fixture `invalid-image-cdn-resolve-signal.ts` 단독 tsc(그 script는 2026-11-08 `check:types:fixtures`로 합쳤다) | 1 | **Expected non-zero.** Negative fixture proving `resolve()` now rejects a call without a lifetime signal (BT-IMG-01). |
|
||||
|
||||
`test:all` stops at `test:unit`, so the later suites above were run directly.
|
||||
|
||||
|
||||
@@ -126,7 +126,7 @@ DOCUMENTATION_READY (off-chain)
|
||||
`DOCUMENTATION_READY`(`verify:documentation`)가 검사하는 범위는 좁다
|
||||
(`scripts/verify-documentation-readiness.ts`).
|
||||
|
||||
- 설치된 라우트마다 수동 접근성 기록 `artifacts/tests/a11y-manual/<ROUTE_ID>.md`가
|
||||
- 설치된 라우트마다 수동 접근성 기록 `docs/accessibility/route-reviews/<ROUTE_ID>.md`가
|
||||
있는지. 없으면 route ID를 적고 실패한다
|
||||
- README가 빌드와 승인 단계가 읽는 환경 변수를 모두 적는지
|
||||
- 입구 문서가 실제 `src` 최상위 폴더와 `.dependency-cruiser.json` 규칙 이름을
|
||||
|
||||
@@ -621,14 +621,14 @@ client route guard는 UX이며 authorization이 아님을 test 이름과 문서
|
||||
공용 컴포넌트는 한 번의 결함이 모든 페이지로 전파되므로 위험도가 높다.
|
||||
|
||||
RP-07의 실행 경로는 `check:design-system`,
|
||||
`check:design-system:fixture`, `check:types:fixture:icon-button`,
|
||||
`check:design-system:fixture`, `check:types:fixtures`(`invalid-icon-button.tsx`),
|
||||
`tests/component/design-system-platform.test.tsx`와
|
||||
`tests/e2e/design-system-interactions.spec.ts`다. Story interaction/visual
|
||||
baseline은 VD-08/RP-10에서 추가하며 현재 runtime gallery를 isolated workshop
|
||||
완료 증거로 사용하지 않는다.
|
||||
|
||||
RP-08의 국제화 실행 경로는 `check:i18n`, `check:i18n:fixture`,
|
||||
`check:types:fixture:i18n-key`, `check:types:fixture:i18n-params`,
|
||||
`check:types:fixtures`(`invalid-message-key.ts`, `invalid-message-params.ts`),
|
||||
`tests/unit/i18n-contract.test.ts`, `tests/component/locale-platform.test.tsx`와
|
||||
`tests/e2e/i18n.spec.ts`다.
|
||||
|
||||
|
||||
+2
-26
@@ -26,27 +26,11 @@
|
||||
"scan:dependency-advisories": "node scripts/scan-dependency-advisories.ts",
|
||||
"check:diagnostics": "node scripts/generate-product-feature-index.ts && node scripts/check-diagnostics.ts",
|
||||
"check:diagnostics:fixture": "node scripts/generate-product-feature-index.ts && node scripts/check-diagnostics.ts --fixture",
|
||||
"check:types": "corepack pnpm check:types:app && corepack pnpm check:types:node && corepack pnpm check:types:test && corepack pnpm check:types:recipes && corepack pnpm check:types:web-worker && corepack pnpm check:types:service-worker",
|
||||
"check:types": "corepack pnpm check:types:app && corepack pnpm check:types:node && corepack pnpm check:types:test && corepack pnpm check:types:service-worker && node scripts/check-typecheck-inputs.ts",
|
||||
"check:types:app": "node scripts/generate-product-feature-index.ts && tsc --project tsconfig.app.json",
|
||||
"check:types:node": "node scripts/generate-product-feature-index.ts && tsc --project tsconfig.node.json",
|
||||
"check:types:test": "node scripts/generate-product-feature-index.ts && tsc --project tsconfig.test.json",
|
||||
"check:types:recipes": "node scripts/check-optional-recipe-types.ts",
|
||||
"check:types:fixture": "tsc -p tests/fixtures/typecheck/tsconfig.port-call.json",
|
||||
"check:types:fixture:ts-port": "tsc -p tests/fixtures/typecheck/tsconfig.port-implementation.json",
|
||||
"check:types:fixture:ts-result": "tsc -p tests/fixtures/typecheck/tsconfig.result-narrowing.json",
|
||||
"check:types:fixture:application-output": "tsc -p tests/fixtures/typecheck/tsconfig.application-output.json",
|
||||
"check:types:fixture:application-input": "tsc -p tests/fixtures/typecheck/tsconfig.application-input.json",
|
||||
"check:types:fixture:feature-input": "tsc -p tests/fixtures/typecheck/tsconfig.feature-input.json",
|
||||
"check:types:fixture:failure-kind": "tsc -p tests/fixtures/typecheck/tsconfig.failure-kind.json",
|
||||
"check:types:fixture:reference-operation": "tsc -p tests/fixtures/typecheck/tsconfig.reference-operation.json",
|
||||
"check:types:fixture:async-overlay": "tsc -p tests/fixtures/typecheck/tsconfig.async-overlay.json",
|
||||
"check:types:fixture:route-runtime": "node scripts/generate-product-feature-index.ts && tsc -p tests/fixtures/typecheck/tsconfig.route-runtime.json",
|
||||
"check:types:fixture:page-action": "node scripts/generate-product-feature-index.ts && tsc -p tests/fixtures/typecheck/tsconfig.page-action.json",
|
||||
"check:types:fixture:icon-button": "node scripts/generate-product-feature-index.ts && tsc -p tests/fixtures/typecheck/tsconfig.icon-button.json",
|
||||
"check:types:fixture:i18n-key": "node scripts/generate-product-feature-index.ts && tsc -p tests/fixtures/typecheck/tsconfig.message-key.json",
|
||||
"check:types:fixture:i18n-params": "node scripts/generate-product-feature-index.ts && tsc -p tests/fixtures/typecheck/tsconfig.message-params.json",
|
||||
"check:types:fixture:diagnostics": "tsc -p tests/fixtures/typecheck/tsconfig.diagnostics-port.json",
|
||||
"check:types:fixture:image-resolve-signal": "tsc -p tests/fixtures/typecheck/tsconfig.image-cdn-resolve-signal.json",
|
||||
"check:types:fixtures": "node scripts/generate-product-feature-index.ts && node scripts/check-type-fixtures.ts",
|
||||
"test:runtime-schema": "node scripts/run-vitest.ts run tests/runtime-schema --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/runtime-schema.xml --passWithNoTests",
|
||||
"test:unit": "node scripts/run-vitest.ts run tests/unit --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/unit.xml",
|
||||
"test:contract": "node scripts/run-vitest.ts run tests/contract --reporter=default --reporter=junit --outputFile.junit=artifacts/tests/contract.xml",
|
||||
@@ -122,15 +106,7 @@
|
||||
"check:ci": "corepack pnpm check:artifact-schemas && node scripts/check-ci-contract.ts && corepack pnpm check:ci-workflow",
|
||||
"update:ci-contract-baseline": "node scripts/update-ci-contract-baseline.ts",
|
||||
"verify:documentation": "node scripts/generate-product-feature-index.ts && node scripts/verify-documentation-readiness.ts",
|
||||
"check:types:web-worker": "tsc --project tsconfig.web-worker.json",
|
||||
"check:types:service-worker": "tsc --project tsconfig.service-worker.json",
|
||||
"check:types:fixture:http-operation-input": "tsc -p tests/fixtures/typecheck/tsconfig.http-operation-input.json",
|
||||
"check:types:fixture:http-wire-mapper": "tsc -p tests/fixtures/typecheck/tsconfig.http-wire-mapper.json",
|
||||
"check:types:fixture:http-operation-id": "tsc -p tests/fixtures/typecheck/tsconfig.http-operation-id.json",
|
||||
"check:types:fixture:http-route-id": "tsc -p tests/fixtures/typecheck/tsconfig.http-route-id.json",
|
||||
"check:types:fixture:feature-contribution-input": "tsc -p tests/fixtures/typecheck/tsconfig.feature-contribution-input.json",
|
||||
"check:types:fixture:feature-capability-selection": "tsc -p tests/fixtures/typecheck/tsconfig.feature-capability-selection.json",
|
||||
"check:types:fixture:direct-feature-composition": "tsc -p tests/fixtures/typecheck/tsconfig.direct-feature-composition.json",
|
||||
"generate:feature-index": "node scripts/generate-product-feature-index.ts",
|
||||
"create:feature": "node scripts/generate-product-feature-index.ts && node scripts/create-feature.ts",
|
||||
"check:feature-index": "node scripts/generate-product-feature-index.ts --check",
|
||||
|
||||
@@ -9,6 +9,7 @@ import { ESLint } from "eslint";
|
||||
import { architectureDependencyReportArtifactSchema } from "./contracts/release-artifacts.ts";
|
||||
import { checkArchitectureLintFixtures } from "./lib/architecture-lint-fixtures.ts";
|
||||
import { formatArchitectureViolation } from "./lib/architecture-violation-message.ts";
|
||||
import { selectRepositoryEntries } from "./lib/repository-layout.ts";
|
||||
import { writeValidatedJsonArtifact } from "./lib/validated-json-artifact.ts";
|
||||
|
||||
type PathRule = Readonly<{ path?: string; pathNot?: string }>;
|
||||
@@ -1044,8 +1045,11 @@ async function runGraphFixtureChecks(): Promise<GraphFixtureResult> {
|
||||
}
|
||||
|
||||
async function inspectTypeScriptOnlyPolicy(): Promise<TypeScriptOnlyPolicy> {
|
||||
const requiredRoots = ["src", "scripts", "tests", ".storybook"] as const;
|
||||
const optionalRoots = ["recipes"] as const;
|
||||
// The typescript-only set of config/repository-layout.json (R2). An optional
|
||||
// root (recipes/) may be gone after a removal drill.
|
||||
const selected = selectRepositoryEntries("typescript-only");
|
||||
const requiredRoots = selected.filter(({ optional }) => !optional).map(({ path }) => path);
|
||||
const optionalRoots = selected.filter(({ optional }) => optional).map(({ path }) => path);
|
||||
const checkedRoots = [...requiredRoots, ...optionalRoots];
|
||||
const files = (
|
||||
await Promise.all(
|
||||
|
||||
@@ -1,62 +0,0 @@
|
||||
import { spawnSync } from "node:child_process";
|
||||
import { readdir } from "node:fs/promises";
|
||||
import { extname, resolve } from "node:path";
|
||||
|
||||
const recipeRoot = resolve("recipes");
|
||||
const pnpmCli = requireEnvironment("npm_execpath");
|
||||
|
||||
if (!(await containsTypeScriptSource(recipeRoot))) {
|
||||
process.stdout.write(
|
||||
"Optional recipe typecheck: SKIP (no recipe TypeScript sources installed)\n",
|
||||
);
|
||||
} else {
|
||||
const result = spawnSync(
|
||||
process.execPath,
|
||||
[pnpmCli, "exec", "tsc", "--project", "tsconfig.recipes.json"],
|
||||
{ stdio: "inherit" },
|
||||
);
|
||||
if (result.error) {
|
||||
throw result.error;
|
||||
}
|
||||
process.exitCode = result.status ?? 1;
|
||||
}
|
||||
|
||||
function requireEnvironment(name: string): string {
|
||||
const value = process.env[name];
|
||||
if (!value) {
|
||||
throw new Error(`${name} is required to typecheck optional recipes`);
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
async function containsTypeScriptSource(directory: string): Promise<boolean> {
|
||||
let entries;
|
||||
try {
|
||||
entries = await readdir(directory, { withFileTypes: true });
|
||||
} catch (error) {
|
||||
if (hasErrorCode(error, "ENOENT")) {
|
||||
return false;
|
||||
}
|
||||
throw error;
|
||||
}
|
||||
|
||||
for (const entry of entries) {
|
||||
const target = resolve(directory, entry.name);
|
||||
if (entry.isDirectory() && (await containsTypeScriptSource(target))) {
|
||||
return true;
|
||||
}
|
||||
if (entry.isFile() && [".ts", ".tsx", ".mts", ".cts"].includes(extname(entry.name))) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
function hasErrorCode(error: unknown, code: string): boolean {
|
||||
return (
|
||||
typeof error === "object" &&
|
||||
error !== null &&
|
||||
"code" in error &&
|
||||
error.code === code
|
||||
);
|
||||
}
|
||||
@@ -54,7 +54,7 @@ try {
|
||||
assertMatchesJsonSchema(
|
||||
JSON.parse(
|
||||
await readFile(
|
||||
"schemas/config/frontend-capability-recipes.schema.json",
|
||||
"config/schemas/recipes/frontend-capability-recipes.schema.json",
|
||||
"utf8",
|
||||
),
|
||||
),
|
||||
|
||||
@@ -748,7 +748,7 @@ if (usesRepositoryBaseline && failures.length === 0) {
|
||||
assertMatchesJsonSchema(
|
||||
JSON.parse(
|
||||
await readFile(
|
||||
"schemas/artifacts/registry-snapshot.schema.json",
|
||||
"config/schemas/artifacts/registry-snapshot.schema.json",
|
||||
"utf8",
|
||||
),
|
||||
),
|
||||
|
||||
@@ -0,0 +1,141 @@
|
||||
import { spawn } from "node:child_process";
|
||||
import { mkdir, readdir, readFile, rm, writeFile } from "node:fs/promises";
|
||||
import path from "node:path";
|
||||
import { fileURLToPath } from "node:url";
|
||||
|
||||
/**
|
||||
* The negative type fixtures (FE-GATE-003). Each fixture under
|
||||
* tests/fixtures/typecheck states on its first line what tsc must say about
|
||||
* it: `// expect: TS2322` (compilation fails and reports TS2322) or
|
||||
* `// expect: pass` (it compiles; tests/fixtures/typecheck/invalid-diagnostics-port.ts
|
||||
* holds one `@ts-expect-error` per violation). Every fixture compiles alone
|
||||
* with tests/fixtures/typecheck/tsconfig.base.json, as the 23 one-file
|
||||
* tsconfigs and package scripts this runner replaces did (design-docs
|
||||
* repo-structure/04-frontend-layout.md §5.3 (가)).
|
||||
*
|
||||
* The check is the one run-ci-gate.ts applied to each of those commands:
|
||||
* tsc exits 1 and its output contains `error TS<code>:`. A fixture without an
|
||||
* expectation line fails, and so does a directory with no fixtures, so a new
|
||||
* fixture cannot be skipped and an empty run cannot pass (R8).
|
||||
*/
|
||||
|
||||
export const TYPE_FIXTURE_ROOT = "tests/fixtures/typecheck";
|
||||
const BASE_CONFIG = `${TYPE_FIXTURE_ROOT}/tsconfig.base.json`;
|
||||
/**
|
||||
* tsc resolves `types` from the tsconfig's directory upwards, so the one-file
|
||||
* tsconfigs are written inside the repository, in the ignored `.tmp/`.
|
||||
*/
|
||||
const CONFIG_ROOT = ".tmp/type-fixtures";
|
||||
const EXPECTATION = /^\/\/ expect: (pass|TS\d{4,5})$/u;
|
||||
/** Helpers that fixtures import are not fixtures. */
|
||||
const FIXTURE_FILE = /^invalid-[\w-]+\.tsx?$/u;
|
||||
const CONCURRENCY = 4;
|
||||
|
||||
export type TypeFixtureExpectation = { kind: "pass" } | { kind: "fail"; code: string };
|
||||
|
||||
export interface TypeFixtureResult {
|
||||
file: string;
|
||||
expectation: TypeFixtureExpectation | undefined;
|
||||
passed: boolean;
|
||||
/** The diagnostic lines that met the expectation, or all output on failure. */
|
||||
evidence: string[];
|
||||
}
|
||||
|
||||
export function parseTypeFixtureExpectation(source: string): TypeFixtureExpectation | undefined {
|
||||
const match = EXPECTATION.exec(source.split("\n", 1)[0]?.trimEnd() ?? "");
|
||||
if (!match?.[1]) return undefined;
|
||||
return match[1] === "pass" ? { kind: "pass" } : { kind: "fail", code: match[1] };
|
||||
}
|
||||
|
||||
export async function listTypeFixtures(root: string): Promise<string[]> {
|
||||
return (await readdir(path.join(root, TYPE_FIXTURE_ROOT)))
|
||||
.filter((name) => FIXTURE_FILE.test(name))
|
||||
.sort()
|
||||
.map((name) => `${TYPE_FIXTURE_ROOT}/${name}`);
|
||||
}
|
||||
|
||||
export function judgeTypeFixture(
|
||||
expectation: TypeFixtureExpectation,
|
||||
exitCode: number | null,
|
||||
output: string,
|
||||
): Pick<TypeFixtureResult, "passed" | "evidence"> {
|
||||
const lines = output.split("\n").filter((line) => line.trim().length > 0);
|
||||
if (expectation.kind === "pass") {
|
||||
return { passed: exitCode === 0, evidence: lines };
|
||||
}
|
||||
const matching = lines.filter((line) => line.includes(`error ${expectation.code}:`));
|
||||
return exitCode === 1 && matching.length > 0
|
||||
? { passed: true, evidence: matching }
|
||||
: { passed: false, evidence: [`tsc exit ${exitCode}`, ...lines] };
|
||||
}
|
||||
|
||||
function runTsc(root: string, config: string): Promise<{ exitCode: number | null; output: string }> {
|
||||
return new Promise((resolve, reject) => {
|
||||
const child = spawn(path.join(root, "node_modules/.bin/tsc"), ["--project", config, "--pretty", "false"], {
|
||||
cwd: root,
|
||||
stdio: ["ignore", "pipe", "pipe"],
|
||||
});
|
||||
let output = "";
|
||||
child.stdout.on("data", (chunk: Buffer) => (output += chunk.toString("utf8")));
|
||||
child.stderr.on("data", (chunk: Buffer) => (output += chunk.toString("utf8")));
|
||||
child.on("error", reject);
|
||||
child.on("close", (exitCode) => resolve({ exitCode, output }));
|
||||
});
|
||||
}
|
||||
|
||||
async function checkTypeFixture(root: string, file: string): Promise<TypeFixtureResult> {
|
||||
const expectation = parseTypeFixtureExpectation(await readFile(path.join(root, file), "utf8"));
|
||||
if (!expectation) {
|
||||
return { file, expectation, passed: false, evidence: ["missing `// expect:` first line"] };
|
||||
}
|
||||
const config = path.join(CONFIG_ROOT, `tsconfig.${path.basename(file).replace(/\.tsx?$/u, "")}.json`);
|
||||
const fromConfig = (target: string) => path.relative(path.dirname(config), target);
|
||||
await writeFile(
|
||||
path.join(root, config),
|
||||
`${JSON.stringify({ extends: fromConfig(BASE_CONFIG), files: [fromConfig(file)] }, null, 2)}\n`,
|
||||
);
|
||||
const { exitCode, output } = await runTsc(root, config);
|
||||
return { file, expectation, ...judgeTypeFixture(expectation, exitCode, output) };
|
||||
}
|
||||
|
||||
export async function checkTypeFixtures(root: string): Promise<TypeFixtureResult[]> {
|
||||
const fixtures = await listTypeFixtures(root);
|
||||
await rm(path.join(root, CONFIG_ROOT), { recursive: true, force: true });
|
||||
await mkdir(path.join(root, CONFIG_ROOT), { recursive: true });
|
||||
const results: TypeFixtureResult[] = new Array(fixtures.length);
|
||||
let next = 0;
|
||||
await Promise.all(
|
||||
Array.from({ length: Math.min(CONCURRENCY, fixtures.length) }, async () => {
|
||||
while (next < fixtures.length) {
|
||||
const index = next++;
|
||||
results[index] = await checkTypeFixture(root, fixtures[index]!);
|
||||
}
|
||||
}),
|
||||
);
|
||||
return results;
|
||||
}
|
||||
|
||||
function describeExpectation(expectation: TypeFixtureExpectation | undefined): string {
|
||||
if (!expectation) return "no expectation";
|
||||
return expectation.kind === "pass" ? "expect pass" : `expect ${expectation.code}`;
|
||||
}
|
||||
|
||||
if (process.argv[1] && path.resolve(process.argv[1]) === fileURLToPath(import.meta.url)) {
|
||||
const results = await checkTypeFixtures(process.cwd());
|
||||
for (const result of results) {
|
||||
process.stdout.write(
|
||||
`${result.passed ? "PASS" : "FAIL"} ${result.file} (${describeExpectation(result.expectation)})\n`,
|
||||
);
|
||||
for (const line of result.evidence) process.stdout.write(` ${line}\n`);
|
||||
}
|
||||
const failed = results.filter(({ passed }) => !passed);
|
||||
if (results.length === 0) {
|
||||
process.stderr.write(`Type fixtures: FAIL (no fixtures under ${TYPE_FIXTURE_ROOT})\n`);
|
||||
process.exitCode = 1;
|
||||
} else if (failed.length > 0) {
|
||||
process.stderr.write(`Type fixtures: FAIL (${failed.length} of ${results.length})\n`);
|
||||
process.exitCode = 1;
|
||||
} else {
|
||||
process.stdout.write(`Type fixtures: PASS (${results.length} fixtures)\n`);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,55 @@
|
||||
import { spawnSync } from "node:child_process";
|
||||
import { readFileSync } from "node:fs";
|
||||
import path from "node:path";
|
||||
import { fileURLToPath } from "node:url";
|
||||
|
||||
/**
|
||||
* R8 of docs/manual/03-outside-feature-folder.md: a check with nothing to
|
||||
* check fails. tsc passes a tsconfig whose `files` is empty when it extends
|
||||
* another one, so `check:types:web-worker` compiled zero files and passed
|
||||
* FE-GATE-003 from 2026-09-25 until it was deleted on 2026-11-08. Every
|
||||
* tsconfig a package script hands to tsc must list at least one file of this
|
||||
* repository (lib and node_modules declarations do not count).
|
||||
*/
|
||||
|
||||
const TSC_PROJECT = /\btsc\s+(?:--project|-p)\s+(\S+)/gu;
|
||||
|
||||
export function typecheckProjects(scripts: Readonly<Record<string, string>>): string[] {
|
||||
const projects = new Set<string>();
|
||||
for (const command of Object.values(scripts)) {
|
||||
for (const match of command.matchAll(TSC_PROJECT)) projects.add(match[1]!);
|
||||
}
|
||||
return [...projects].sort();
|
||||
}
|
||||
|
||||
export function ownInputFiles(listed: string): string[] {
|
||||
return listed
|
||||
.split("\n")
|
||||
.map((line) => line.trim())
|
||||
.filter((line) => line.length > 0 && !line.split(path.sep).includes("node_modules"));
|
||||
}
|
||||
|
||||
if (process.argv[1] && path.resolve(process.argv[1]) === fileURLToPath(import.meta.url)) {
|
||||
const scripts = (JSON.parse(readFileSync("package.json", "utf8")) as { scripts: Record<string, string> }).scripts;
|
||||
const projects = typecheckProjects(scripts);
|
||||
const counts = projects.map((project) => {
|
||||
const result = spawnSync(path.resolve("node_modules/.bin/tsc"), ["--project", project, "--listFilesOnly"], {
|
||||
encoding: "utf8",
|
||||
});
|
||||
if (result.error) throw result.error;
|
||||
return { project, files: ownInputFiles(result.stdout).length };
|
||||
});
|
||||
const empty = counts.filter(({ files }) => files === 0);
|
||||
if (projects.length === 0 || empty.length > 0) {
|
||||
process.stderr.write(
|
||||
projects.length === 0
|
||||
? "Typecheck inputs: FAIL (no package script runs tsc --project)\n"
|
||||
: `Typecheck inputs: FAIL (no input files: ${empty.map(({ project }) => project).join(", ")})\n`,
|
||||
);
|
||||
process.exitCode = 1;
|
||||
} else {
|
||||
process.stdout.write(
|
||||
`Typecheck inputs: PASS (${counts.map(({ project, files }) => `${project} ${files}`).join(", ")})\n`,
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -880,7 +880,7 @@ const manualA11yResultSchema = z
|
||||
})
|
||||
.strict()
|
||||
.superRefine((result, context) => {
|
||||
if (result.path !== `artifacts/tests/a11y-manual/${result.routeId}.md`) {
|
||||
if (result.path !== `docs/accessibility/route-reviews/${result.routeId}.md`) {
|
||||
context.addIssue({ code: "custom", path: ["path"], message: "path must match routeId" });
|
||||
}
|
||||
const hasIdentity = Boolean(
|
||||
@@ -1429,7 +1429,7 @@ export const documentationReviewArtifactSchema = z
|
||||
reportDigestValid: z.boolean(),
|
||||
/**
|
||||
* The manual accessibility review scope: the installed routes that have no
|
||||
* record file under artifacts/tests/a11y-manual/. It is derived from the
|
||||
* record file under docs/accessibility/route-reviews/. It is derived from the
|
||||
* route registry, not read off a document (1101/14-05).
|
||||
*/
|
||||
routeScope: z.array(
|
||||
@@ -1472,6 +1472,18 @@ export const documentationReviewArtifactSchema = z
|
||||
})
|
||||
.strict(),
|
||||
).min(1),
|
||||
// R6·R7 of docs/manual/03-outside-feature-folder.md: a manual example that
|
||||
// points at a deletable sample feature, or infrastructure configuration
|
||||
// copied into a current document.
|
||||
layoutRuleViolations: z.array(
|
||||
z
|
||||
.object({
|
||||
path: nonEmptyString,
|
||||
rule: z.enum(["R6", "R7"]),
|
||||
detail: nonEmptyString,
|
||||
})
|
||||
.strict(),
|
||||
),
|
||||
results: z.array(
|
||||
z
|
||||
.object({
|
||||
@@ -1523,9 +1535,10 @@ export const documentationReviewArtifactSchema = z
|
||||
entry.missingScripts.length === 0 &&
|
||||
entry.unknownGateIds.length === 0,
|
||||
) &&
|
||||
artifact.layoutRuleViolations.length === 0 &&
|
||||
artifact.results.every(({ passed }) => passed))
|
||||
) {
|
||||
context.addIssue({ code: "custom", path: ["passed"], message: "must agree with report digest, documented scope, source structure, document references and review results" });
|
||||
context.addIssue({ code: "custom", path: ["passed"], message: "must agree with report digest, documented scope, source structure, document references, layout rules and review results" });
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -375,7 +375,7 @@ export function planFeature(
|
||||
: []),
|
||||
...planned.map(
|
||||
(route) =>
|
||||
[`artifacts/tests/a11y-manual/${route.routeId}.md`, renderA11yRecord(route.routeId)] as const,
|
||||
[`docs/accessibility/route-reviews/${route.routeId}.md`, renderA11yRecord(route.routeId)] as const,
|
||||
),
|
||||
]);
|
||||
return Object.freeze({
|
||||
@@ -1767,7 +1767,7 @@ function report(plan: FeaturePlan): string {
|
||||
"",
|
||||
"Next:",
|
||||
` 1. Before a release, have a person review and sign ${plan.routes
|
||||
.map((route) => `artifacts/tests/a11y-manual/${route.routeId}.md`)
|
||||
.map((route) => `docs/accessibility/route-reviews/${route.routeId}.md`)
|
||||
.join(", ")} (FE-GATE-028). The merge gates check only their format.`,
|
||||
" 2. Run the merge gates: corepack pnpm ci:gate -- FE-GATE-<NNN> for each gate of the merge stage in config/ci/gates.json (README lists the loop). test:feature-scaffold runs them on a generated feature except the browser gates FE-GATE-008/009 and test:system.",
|
||||
` The feature's own tests: node scripts/run-vitest.ts run tests/features/${plan.id} (test:coverage runs them in CI)`,
|
||||
|
||||
@@ -15,22 +15,22 @@ import { writeValidatedJsonArtifact } from "./lib/validated-json-artifact.ts";
|
||||
|
||||
const ARTIFACT_SCHEMA_DEFINITIONS = Object.freeze([
|
||||
{
|
||||
relativePath: "schemas/artifacts/build-manifest.schema.json",
|
||||
relativePath: "config/schemas/artifacts/build-manifest.schema.json",
|
||||
id: undefined,
|
||||
schema: buildManifestArtifactSchema,
|
||||
},
|
||||
{
|
||||
relativePath: "schemas/artifacts/dependency-inventory.schema.json",
|
||||
relativePath: "config/schemas/artifacts/dependency-inventory.schema.json",
|
||||
id: "https://clean-architecture-frontend.local/schemas/dependency-inventory.schema.json",
|
||||
schema: dependencyInventoryArtifactSchema,
|
||||
},
|
||||
{
|
||||
relativePath: "schemas/artifacts/registry-snapshot.schema.json",
|
||||
relativePath: "config/schemas/artifacts/registry-snapshot.schema.json",
|
||||
id: undefined,
|
||||
schema: registrySnapshotArtifactSchema,
|
||||
},
|
||||
{
|
||||
relativePath: "schemas/artifacts/supply-chain-verification.schema.json",
|
||||
relativePath: "config/schemas/artifacts/supply-chain-verification.schema.json",
|
||||
id: "https://clean-architecture-frontend.local/schemas/supply-chain-verification.schema.json",
|
||||
schema: supplyChainVerificationArtifactSchema,
|
||||
},
|
||||
|
||||
@@ -122,12 +122,12 @@ export async function verifyLocalSupplyChainEvidence(
|
||||
|
||||
for (const [schemaPath, artifact, label] of [
|
||||
[
|
||||
"schemas/artifacts/dependency-inventory.schema.json",
|
||||
"config/schemas/artifacts/dependency-inventory.schema.json",
|
||||
inventory,
|
||||
"dependency inventory",
|
||||
],
|
||||
[
|
||||
"schemas/artifacts/supply-chain-verification.schema.json",
|
||||
"config/schemas/artifacts/supply-chain-verification.schema.json",
|
||||
verification,
|
||||
"supply-chain verification",
|
||||
],
|
||||
@@ -1020,7 +1020,7 @@ export async function assessLocalEvidenceForProducer(input: Readonly<{
|
||||
assertMatchesJsonSchema(
|
||||
await readJson(
|
||||
repositoryRoot,
|
||||
"schemas/artifacts/build-manifest.schema.json",
|
||||
"config/schemas/artifacts/build-manifest.schema.json",
|
||||
),
|
||||
buildManifest,
|
||||
"build manifest",
|
||||
|
||||
@@ -58,6 +58,9 @@ export const LOCAL_EVIDENCE_VERIFIER_SOURCE_PATHS = Object.freeze([
|
||||
] as const);
|
||||
|
||||
export const LOCAL_EVIDENCE_POLICY_INPUT_PATHS = Object.freeze([
|
||||
"config/schemas/artifacts/build-manifest.schema.json",
|
||||
"config/schemas/artifacts/dependency-inventory.schema.json",
|
||||
"config/schemas/artifacts/supply-chain-verification.schema.json",
|
||||
"config/security/dependency-baseline.approval.json",
|
||||
"config/security/dependency-baseline.json",
|
||||
"config/security/dependency-change-evidence.json",
|
||||
@@ -65,9 +68,6 @@ export const LOCAL_EVIDENCE_POLICY_INPUT_PATHS = Object.freeze([
|
||||
"config/security/secret-scan-policy.json",
|
||||
"config/security/vulnerability-exceptions.json",
|
||||
"config/security/vulnerability-policy.json",
|
||||
"schemas/artifacts/build-manifest.schema.json",
|
||||
"schemas/artifacts/dependency-inventory.schema.json",
|
||||
"schemas/artifacts/supply-chain-verification.schema.json",
|
||||
...LOCAL_EVIDENCE_VERIFIER_SOURCE_PATHS,
|
||||
] as const);
|
||||
|
||||
|
||||
@@ -20,23 +20,20 @@ import {
|
||||
linkFixtureNodeModules,
|
||||
} from "./fixture-node-modules.ts";
|
||||
import { generateCiWorkflow } from "../generate-ci-workflow.ts";
|
||||
import { selectRepositoryPaths } from "./repository-layout.ts";
|
||||
import { updateCiContractBaseline } from "../update-ci-contract-baseline.ts";
|
||||
|
||||
export const REMOVAL_FIXTURE_COPY_TARGETS = Object.freeze([
|
||||
"src", "tests", "recipes", "scripts", "schemas", "config", "public",
|
||||
".gitea", ".storybook", "index.html", "package.json", "tsconfig.base.json",
|
||||
"tsconfig.json", "tsconfig.app.json", "tsconfig.node.json", "tsconfig.test.json",
|
||||
"tsconfig.recipes.json", "tsconfig.web-worker.json", "tsconfig.service-worker.json",
|
||||
"vite.service-worker.config.ts", "vite.config.ts", "vitest.config.ts",
|
||||
"playwright.config.ts", "playwright.capabilities.config.ts", "playwright.dev.config.ts",
|
||||
"playwright.storybook.config.ts", "playwright.visual.config.ts", "eslint.config.ts",
|
||||
".dependency-cruiser.json", ".nvmrc", ".gitignore",
|
||||
// Install and workspace identity. Without these the fixture is not the same
|
||||
// project: `corepack pnpm` resolves a different store, and the provider
|
||||
// suites — which build a release candidate containing `pnpm-lock.yaml` —
|
||||
// cannot assemble their fixture at all.
|
||||
".npmrc", "pnpm-lock.yaml", "pnpm-workspace.yaml",
|
||||
] as const);
|
||||
/**
|
||||
* The fixture-copy set of config/repository-layout.json (R2). It includes the
|
||||
* install and workspace identity (`.npmrc`, `pnpm-lock.yaml`,
|
||||
* `pnpm-workspace.yaml`): without them the fixture is not the same project,
|
||||
* `corepack pnpm` resolves a different store, and the provider suites — which
|
||||
* build a release candidate containing `pnpm-lock.yaml` — cannot assemble
|
||||
* their fixture at all. It also carries the manual a11y review records
|
||||
* (docs/accessibility/route-reviews), which unit tests read, without the rest
|
||||
* of `docs/`.
|
||||
*/
|
||||
export const REMOVAL_FIXTURE_COPY_TARGETS = selectRepositoryPaths("fixture-copy");
|
||||
|
||||
/**
|
||||
* This is the only copy-target list. Each removal script used to keep its own,
|
||||
@@ -53,14 +50,7 @@ export const REMOVAL_FIXTURE_COPY_TARGETS = Object.freeze([
|
||||
* the documents describe the capability they delete, and what those drills
|
||||
* prove is that the code still builds and tests without it.
|
||||
*/
|
||||
export const REMOVAL_FIXTURE_DOCUMENT_TARGETS = Object.freeze([
|
||||
"README.md",
|
||||
"CHANGELOG.md",
|
||||
"docs",
|
||||
// The root rule book. docs/README.md section 1 links it, so verify:documentation
|
||||
// in the fixture reads it as a current contract document.
|
||||
"AGENTS.md",
|
||||
] as const);
|
||||
export const REMOVAL_FIXTURE_DOCUMENT_TARGETS = selectRepositoryPaths("fixture-documents");
|
||||
|
||||
/**
|
||||
* 1103/02-06. Tests that read REMOVAL_FIXTURE_DOCUMENT_TARGETS. A fixture
|
||||
|
||||
@@ -0,0 +1,141 @@
|
||||
import { readFileSync } from "node:fs";
|
||||
|
||||
/**
|
||||
* The repository root registry, config/repository-layout.json (R1 in
|
||||
* docs/manual/03-outside-feature-folder.md). Every tracked root item has an
|
||||
* entry, and every list of root paths is a named set chosen from it (R2).
|
||||
* Seven places used to keep their own literal lists of root paths, each a
|
||||
* different subset, so moving one root item meant editing all seven
|
||||
* (design-docs repo-structure/04-frontend-layout.md §2.4).
|
||||
*/
|
||||
|
||||
export const REPOSITORY_LAYOUT_SETS = Object.freeze([
|
||||
"fixture-copy",
|
||||
"fixture-documents",
|
||||
"secret-scan",
|
||||
"history-free",
|
||||
"scale-source",
|
||||
"vite-build",
|
||||
"typescript-only",
|
||||
] as const);
|
||||
export type RepositoryLayoutSet = (typeof REPOSITORY_LAYOUT_SETS)[number];
|
||||
|
||||
export const REPOSITORY_LAYOUT_KINDS = Object.freeze([
|
||||
"source",
|
||||
"tool-convention",
|
||||
"gate-input",
|
||||
"document",
|
||||
"history",
|
||||
"output",
|
||||
] as const);
|
||||
export type RepositoryLayoutKind = (typeof REPOSITORY_LAYOUT_KINDS)[number];
|
||||
|
||||
export type RepositoryLayoutEntry = Readonly<{
|
||||
/** A root item name: one path segment, no slash. */
|
||||
path: string;
|
||||
kind: RepositoryLayoutKind;
|
||||
role: string;
|
||||
readBy: string;
|
||||
/** A removal drill or a product copy may not have it; a selection skips it when absent. */
|
||||
optional: boolean;
|
||||
/** The sets that select the whole item. */
|
||||
sets: readonly RepositoryLayoutSet[];
|
||||
/** The sets that select only these paths inside the item. */
|
||||
setPaths: Readonly<Partial<Record<RepositoryLayoutSet, readonly string[]>>>;
|
||||
}>;
|
||||
|
||||
export const REPOSITORY_LAYOUT_FILE = "config/repository-layout.json";
|
||||
|
||||
export function parseRepositoryLayout(value: unknown): readonly RepositoryLayoutEntry[] {
|
||||
const document = record(value, "layout");
|
||||
if (document["schemaVersion"] !== 1) throw new Error("layout: schemaVersion must be 1");
|
||||
const entries = document["entries"];
|
||||
if (!Array.isArray(entries) || entries.length === 0) {
|
||||
throw new Error("layout: entries must be a non-empty array");
|
||||
}
|
||||
const seen = new Set<string>();
|
||||
return Object.freeze(
|
||||
entries.map((raw, index) => {
|
||||
const entry = record(raw, `entries[${index}]`);
|
||||
const at = `entries[${index}]`;
|
||||
const itemPath = text(entry["path"], `${at}.path`);
|
||||
if (itemPath.includes("/")) throw new Error(`${at}.path: a root item has no slash: ${itemPath}`);
|
||||
if (seen.has(itemPath)) throw new Error(`${at}.path: duplicate root item ${itemPath}`);
|
||||
seen.add(itemPath);
|
||||
const kind = text(entry["kind"], `${at}.kind`);
|
||||
if (!(REPOSITORY_LAYOUT_KINDS as readonly string[]).includes(kind)) {
|
||||
throw new Error(`${at}.kind: unknown kind ${kind}`);
|
||||
}
|
||||
const sets = (entry["sets"] ?? []) as unknown;
|
||||
if (!Array.isArray(sets)) throw new Error(`${at}.sets must be an array`);
|
||||
const setPaths = record(entry["setPaths"] ?? {}, `${at}.setPaths`);
|
||||
for (const set of [...sets, ...Object.keys(setPaths)]) {
|
||||
if (!(REPOSITORY_LAYOUT_SETS as readonly string[]).includes(set as string)) {
|
||||
throw new Error(`${at}: unknown set ${String(set)}`);
|
||||
}
|
||||
}
|
||||
for (const [set, paths] of Object.entries(setPaths)) {
|
||||
if (!Array.isArray(paths) || paths.length === 0) {
|
||||
throw new Error(`${at}.setPaths.${set} must be a non-empty array`);
|
||||
}
|
||||
for (const inner of paths) {
|
||||
if (typeof inner !== "string" || !inner.startsWith(`${itemPath}/`)) {
|
||||
throw new Error(`${at}.setPaths.${set}: ${String(inner)} is not inside ${itemPath}`);
|
||||
}
|
||||
}
|
||||
if (sets.includes(set)) throw new Error(`${at}: ${set} selects the whole item and paths in it`);
|
||||
}
|
||||
return Object.freeze({
|
||||
path: itemPath,
|
||||
kind: kind as RepositoryLayoutKind,
|
||||
role: text(entry["role"], `${at}.role`),
|
||||
readBy: text(entry["readBy"], `${at}.readBy`),
|
||||
optional: entry["optional"] === true,
|
||||
sets: Object.freeze([...sets] as RepositoryLayoutSet[]),
|
||||
setPaths: Object.freeze(setPaths as Partial<Record<RepositoryLayoutSet, readonly string[]>>),
|
||||
});
|
||||
}),
|
||||
);
|
||||
}
|
||||
|
||||
export const REPOSITORY_LAYOUT: readonly RepositoryLayoutEntry[] = parseRepositoryLayout(
|
||||
JSON.parse(readFileSync(new URL(`../../${REPOSITORY_LAYOUT_FILE}`, import.meta.url), "utf8")),
|
||||
);
|
||||
|
||||
/** The paths a set selects, in registry order. */
|
||||
export function selectRepositoryPaths(
|
||||
set: RepositoryLayoutSet,
|
||||
layout: readonly RepositoryLayoutEntry[] = REPOSITORY_LAYOUT,
|
||||
): readonly string[] {
|
||||
return Object.freeze(
|
||||
layout.flatMap((entry) =>
|
||||
entry.sets.includes(set) ? [entry.path] : [...(entry.setPaths[set] ?? [])],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
/** Like selectRepositoryPaths, with whether a drill or a copy may lack each path. */
|
||||
export function selectRepositoryEntries(
|
||||
set: RepositoryLayoutSet,
|
||||
layout: readonly RepositoryLayoutEntry[] = REPOSITORY_LAYOUT,
|
||||
): readonly Readonly<{ path: string; optional: boolean }>[] {
|
||||
return Object.freeze(
|
||||
layout.flatMap((entry) =>
|
||||
(entry.sets.includes(set) ? [entry.path] : [...(entry.setPaths[set] ?? [])]).map(
|
||||
(selected) => Object.freeze({ path: selected, optional: entry.optional }),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
function record(value: unknown, at: string): Record<string, unknown> {
|
||||
if (typeof value !== "object" || value === null || Array.isArray(value)) {
|
||||
throw new Error(`${at} must be an object`);
|
||||
}
|
||||
return value as Record<string, unknown>;
|
||||
}
|
||||
|
||||
function text(value: unknown, at: string): string {
|
||||
if (typeof value !== "string" || value.trim() === "") throw new Error(`${at} must be a non-empty string`);
|
||||
return value;
|
||||
}
|
||||
@@ -1,3 +1,5 @@
|
||||
import { selectRepositoryPaths } from "./repository-layout.ts";
|
||||
|
||||
/**
|
||||
* 1105/15-03. The files `vite build` reads from the repository root, for the
|
||||
* measurements and tests that copy them into a temporary root and build
|
||||
@@ -7,15 +9,6 @@
|
||||
* a new local import in vite.config.ts broke both, and both had to be edited
|
||||
* (7f9a515, 799ab7f). tests/unit/vite-build-inputs.test.ts fails, naming the
|
||||
* file, when vite.config.ts imports a local file this list does not cover.
|
||||
* The list is the vite-build set of config/repository-layout.json (R2).
|
||||
*/
|
||||
export const VITE_BUILD_INPUTS = Object.freeze([
|
||||
"src",
|
||||
"public",
|
||||
"index.html",
|
||||
"package.json",
|
||||
"vite.config.ts",
|
||||
"tsconfig.base.json",
|
||||
"tsconfig.app.json",
|
||||
"scripts/lib/run-isolation.ts",
|
||||
"scripts/lib/vite-module-inventory.ts",
|
||||
] as const);
|
||||
export const VITE_BUILD_INPUTS = selectRepositoryPaths("vite-build");
|
||||
|
||||
@@ -42,7 +42,6 @@ try {
|
||||
});
|
||||
|
||||
const removedCiScripts = new Set([
|
||||
"check:types:recipes",
|
||||
"test:recipes",
|
||||
"check:optional-recipes",
|
||||
"check:optional-recipes:source",
|
||||
|
||||
@@ -24,7 +24,7 @@ type ManualA11yResult = Readonly<{
|
||||
if (process.argv.includes("--format-only")) {
|
||||
const failures: string[] = [];
|
||||
for (const routeId of MANUAL_A11Y_ROUTE_IDS) {
|
||||
const path = `artifacts/tests/a11y-manual/${routeId}.md`;
|
||||
const path = `docs/accessibility/route-reviews/${routeId}.md`;
|
||||
const record = await readFile(path, "utf8").catch(() => null);
|
||||
const invalid = record === null ? ["missing record"] : validateManualA11yRecordFormat(record, routeId);
|
||||
if (invalid.length > 0) failures.push(`${path}: ${invalid.join(", ")}`);
|
||||
@@ -41,7 +41,7 @@ if (process.argv.includes("--format-only")) {
|
||||
|
||||
const results: ManualA11yResult[] = [];
|
||||
for (const routeId of MANUAL_A11Y_ROUTE_IDS) {
|
||||
const path = `artifacts/tests/a11y-manual/${routeId}.md`;
|
||||
const path = `docs/accessibility/route-reviews/${routeId}.md`;
|
||||
const evidence = await readFile(path, "utf8");
|
||||
const validation = validateManualA11yEvidence(evidence);
|
||||
const failures =
|
||||
|
||||
@@ -21,7 +21,7 @@ import { writeValidatedJsonArtifact } from "./lib/validated-json-artifact.ts";
|
||||
* every new feature edit two template-owned documents (1101/14-05), so the
|
||||
* documents now name this folder and the record files are what is checked.
|
||||
*/
|
||||
const MANUAL_A11Y_RECORDS = "artifacts/tests/a11y-manual/";
|
||||
const MANUAL_A11Y_RECORDS = "docs/accessibility/route-reviews/";
|
||||
|
||||
type DocumentationReview = Readonly<{
|
||||
sourcePath: string;
|
||||
@@ -165,7 +165,8 @@ const DOCUMENT_INDEX = "docs/README.md";
|
||||
const UNCHECKED_DOCUMENTS = new Set(["CHANGELOG.md"]);
|
||||
const NOT_CREATED = new Set([
|
||||
// Reserved by generic-worker-has-no-network-or-credentials. The generic CPU
|
||||
// worker is NOT_SELECTED (tsconfig.web-worker.json).
|
||||
// worker is NOT_SELECTED; docs/manual/03-outside-feature-folder.md says how
|
||||
// to add it with its own tsconfig.
|
||||
"src/adapters/web-worker",
|
||||
]);
|
||||
// pnpm's own commands, which are not package scripts.
|
||||
@@ -408,6 +409,48 @@ const documentReferencesValid = documentReferences.every(
|
||||
(entry) => entry.missingPaths.length === 0 && entry.missingScripts.length === 0 && entry.unknownGateIds.length === 0,
|
||||
);
|
||||
|
||||
// Repository layout rules of docs/manual/03-outside-feature-folder.md.
|
||||
// R6: the manual's examples point at generator output or at code blocks in
|
||||
// the manual, never at a sample feature a copy is meant to delete (the
|
||||
// template's own sample took the manual's examples with it on 2026-11-07).
|
||||
// R7: host, cluster and infrastructure configuration (nginx, Kubernetes,
|
||||
// Helm, Terraform) lives in the infrastructure repository; a current document
|
||||
// links to it and states the host contract (config/hosting/, FE-GATE-019)
|
||||
// instead of carrying a copy. The history folders are records and keep what
|
||||
// they recorded.
|
||||
// Built from pieces: tests/unit/deletable-history-documents.test.ts fails on
|
||||
// code that names a history folder, and this names them to skip them.
|
||||
const HISTORY_DOCUMENT_FOLDERS = ["history", "reviews", "superpowers"].map((folder) => `docs/${folder}/`);
|
||||
const INFRASTRUCTURE_FENCE = /^\s*```\s*(nginx|hcl|terraform|helm)\b/iu;
|
||||
const INFRASTRUCTURE_MANIFEST =
|
||||
/^\s*kind:\s*(Deployment|StatefulSet|DaemonSet|Ingress|Service|ConfigMap|CronJob|HelmRelease|Kustomization)\s*$/u;
|
||||
const sampleFeaturePaths = REMOVABLE_TEMPLATE_FEATURES.flatMap((feature) => removableTemplateFeaturePaths(feature));
|
||||
const currentDocuments = [
|
||||
"README.md",
|
||||
...((await readdir("docs", { recursive: true }).catch(() => [])) as string[])
|
||||
.filter((name) => name.endsWith(".md"))
|
||||
.map((name) => `docs/${name}`)
|
||||
.filter((name) => !HISTORY_DOCUMENT_FOLDERS.some((folder) => name.startsWith(folder))),
|
||||
].sort();
|
||||
const layoutRuleViolations: { path: string; rule: "R6" | "R7"; detail: string }[] = [];
|
||||
for (const document of currentDocuments) {
|
||||
const text = await readFile(document, "utf8").catch(() => null);
|
||||
if (text === null) continue;
|
||||
let fenced = false;
|
||||
text.split("\n").forEach((line, index) => {
|
||||
if (/^\s*```/u.test(line)) fenced = !fenced;
|
||||
if (INFRASTRUCTURE_FENCE.test(line) || (fenced && INFRASTRUCTURE_MANIFEST.test(line))) {
|
||||
layoutRuleViolations.push({ path: document, rule: "R7", detail: `line ${index + 1}: ${line.trim()}` });
|
||||
}
|
||||
if (!document.startsWith("docs/manual/")) return;
|
||||
for (const samplePath of sampleFeaturePaths) {
|
||||
if (line.includes(samplePath)) {
|
||||
layoutRuleViolations.push({ path: document, rule: "R6", detail: `line ${index + 1}: ${samplePath}` });
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// 1101/14-06. Each failed check is named, so the stderr points at the file to
|
||||
// fix rather than at the diagram review whatever failed. 1101/14-05: the last
|
||||
// two only compare the two hand-kept copies of the 2026-07-18 diagram review;
|
||||
@@ -418,6 +461,7 @@ const failedChecks = [
|
||||
...(missingRuntimeVariables.length === 0 ? [] : ["runtime variables"]),
|
||||
...(sourceStructureDocumented ? [] : ["source structure"]),
|
||||
...(documentReferencesValid ? [] : ["document references"]),
|
||||
...(layoutRuleViolations.length === 0 ? [] : ["repository layout rules"]),
|
||||
...(reportDigestValid ? [] : ["2026-07-18 diagram review copy digest"]),
|
||||
...(results.length === 2 && results.every((result) => result.passed)
|
||||
? []
|
||||
@@ -441,6 +485,7 @@ await writeValidatedJsonArtifact({
|
||||
missingRuntimeVariables,
|
||||
sourceStructure,
|
||||
documentReferences,
|
||||
layoutRuleViolations,
|
||||
results,
|
||||
passed,
|
||||
},
|
||||
@@ -478,6 +523,11 @@ if (!passed) {
|
||||
);
|
||||
}
|
||||
}
|
||||
for (const violation of layoutRuleViolations) {
|
||||
process.stderr.write(
|
||||
`${violation.path} breaks ${violation.rule} of docs/manual/03-outside-feature-folder.md: ${violation.detail}\n`,
|
||||
);
|
||||
}
|
||||
if (documentReferences.some((entry) => entry.missingPaths.some((file) => file.startsWith("../")))) {
|
||||
const checked = [...pairedTrees]
|
||||
.filter(([, tree]) => "paths" in tree)
|
||||
|
||||
@@ -5,6 +5,8 @@ import { mkdir, readdir, readFile, stat, writeFile } from "node:fs/promises";
|
||||
import { arch, platform, userInfo } from "node:os";
|
||||
import path from "node:path";
|
||||
|
||||
import { selectRepositoryPaths } from "./lib/repository-layout.ts";
|
||||
|
||||
/**
|
||||
* Executable evidence for the extreme-scale acceptance matrix.
|
||||
*
|
||||
@@ -46,20 +48,8 @@ export const EXTREME_SCALE_GATES = Object.freeze([
|
||||
"check:scale:release",
|
||||
] as const);
|
||||
|
||||
/** Inputs whose content defines "the current code" for this evidence. */
|
||||
const SOURCE_ROOTS = Object.freeze(["src", "scripts", "tests", "config", ".storybook", "recipes"]);
|
||||
const SOURCE_FILES = Object.freeze([
|
||||
"package.json",
|
||||
"pnpm-lock.yaml",
|
||||
".dependency-cruiser.json",
|
||||
"eslint.config.ts",
|
||||
"vite.config.ts",
|
||||
"vitest.config.ts",
|
||||
"tsconfig.json",
|
||||
"tsconfig.app.json",
|
||||
"tsconfig.test.json",
|
||||
"tsconfig.node.json",
|
||||
]);
|
||||
/** Inputs whose content defines "the current code": the scale-source set of config/repository-layout.json (R2). */
|
||||
const SOURCE_PATHS = selectRepositoryPaths("scale-source");
|
||||
|
||||
async function listFiles(directory: string): Promise<string[]> {
|
||||
const found: string[] = [];
|
||||
@@ -80,8 +70,17 @@ async function listFiles(directory: string): Promise<string[]> {
|
||||
/** sha256 over every source input (path + content), in a stable order. */
|
||||
export async function sourceDigest(root: string): Promise<Readonly<{ digest: string; files: number }>> {
|
||||
const files = [
|
||||
...(await Promise.all(SOURCE_ROOTS.map((entry) => listFiles(path.join(root, entry))))).flat(),
|
||||
...SOURCE_FILES.map((file) => path.join(root, file)).filter((file) => existsSync(file)),
|
||||
...(
|
||||
await Promise.all(
|
||||
SOURCE_PATHS.map((entry) => path.join(root, entry)).map(async (target) =>
|
||||
(await stat(target).catch(() => null))?.isDirectory()
|
||||
? listFiles(target)
|
||||
: existsSync(target)
|
||||
? [target]
|
||||
: [],
|
||||
),
|
||||
)
|
||||
).flat(),
|
||||
]
|
||||
.map((file) => path.relative(root, file))
|
||||
.sort();
|
||||
|
||||
@@ -129,7 +129,7 @@ if (liveTarget?.passed && !slotEmpty) {
|
||||
} else {
|
||||
mode = "fixture";
|
||||
const fixture = await readDocument(
|
||||
"config/hosting/response-headers.fixture.json",
|
||||
"tests/fixtures/hosting/response-headers.json",
|
||||
);
|
||||
responses = responseHeaders(fixture.responses);
|
||||
}
|
||||
|
||||
@@ -95,7 +95,7 @@ const buildManifestDocument: unknown = JSON.parse(
|
||||
);
|
||||
assertMatchesJsonSchema(
|
||||
JSON.parse(
|
||||
await readFile("schemas/artifacts/build-manifest.schema.json", "utf8"),
|
||||
await readFile("config/schemas/artifacts/build-manifest.schema.json", "utf8"),
|
||||
),
|
||||
buildManifestDocument,
|
||||
"build manifest",
|
||||
|
||||
Vendored
@@ -1,3 +1,4 @@
|
||||
// expect: TS2739
|
||||
import type { ApplicationApi } from "../../../src/application/create-application.ts";
|
||||
|
||||
export const incompleteApplication: ApplicationApi = {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
import type { ApplicationOutputPorts } from "../../../src/application/create-application.ts";
|
||||
|
||||
export const invalidOutputPorts: ApplicationOutputPorts = {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
import type { AsyncOverlay } from "../../../src/application/view-models/async-state.ts";
|
||||
|
||||
export const invalidPendingConflict: AsyncOverlay = {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: pass
|
||||
import type { DiagnosticsPort } from "../../../src/application/ports/diagnostics-port.ts";
|
||||
import type { TelemetryPort } from "../../../src/application/ports/telemetry-port.ts";
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2345
|
||||
import type { InstalledHttpOperationExecutor } from "../../../src/adapters/http/index.ts";
|
||||
import { composeFeatureAdapterInputs } from "../../../src/features/feature-adapter-contribution.ts";
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
import type { AppFailure } from "../../../src/contracts/errors.ts";
|
||||
|
||||
export const invalidFailure: AppFailure = {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2339
|
||||
import { defineFeatureAdapterContribution } from "../../../src/features/feature-adapter-contribution.ts";
|
||||
import { createFixtureFeatureInstalledInput } from "./fixture-feature-contract.ts";
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
import { defineFeatureAdapterContribution } from "../../../src/features/feature-adapter-contribution.ts";
|
||||
import type {} from "./fixture-feature-contract.ts";
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2345
|
||||
import type { ApplicationApi } from "../../../src/application/ports/in/application-api.ts";
|
||||
import type { FixtureFeatureInput } from "./fixture-feature-contract.ts";
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2345
|
||||
import {
|
||||
createFeatureHttpBinding,
|
||||
defineFeatureHttpOperation,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2353
|
||||
import type { FixtureHttpBinding } from "./fixture-feature-contract.ts";
|
||||
|
||||
declare const http: FixtureHttpBinding;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
import { defineFeatureHttpOperationForRoutes } from "../../../src/adapters/http/index.ts";
|
||||
import {
|
||||
mapEntityPayload,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
import { defineFeatureHttpOperation } from "../../../src/adapters/http/index.ts";
|
||||
import { TEST_GET_ENTITY_CONTRACT } from "./fixture-feature-contract.ts";
|
||||
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2741
|
||||
import { IconButton, MenuIcon } from "../../../src/presentation/design-system/index.ts";
|
||||
|
||||
export const InvalidIconButton = <IconButton><MenuIcon /></IconButton>;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2741
|
||||
import type {
|
||||
ImageAssetReference,
|
||||
ImageCdnPresentationPort,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2345
|
||||
import { formatMessage } from "../../../src/presentation/i18n/index.ts";
|
||||
|
||||
formatMessage("ko-KR", "unknown.translation.key");
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2554
|
||||
import { formatMessage } from "../../../src/presentation/i18n/index.ts";
|
||||
|
||||
formatMessage("en-US", "route.documentTitle");
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS1360
|
||||
import type { PageActionDefinition } from "../../../src/presentation/templates/index.ts";
|
||||
|
||||
export const activeButtonWithoutCallback = {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
// This deliberately failing fixture proves that TypeScript rejects a wrong shape.
|
||||
|
||||
function execute(request: { operationId: string }) {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2322
|
||||
interface ClockPort {
|
||||
now(): number;
|
||||
}
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2741
|
||||
import type { FixtureHttpBinding } from "./fixture-feature-contract.ts";
|
||||
|
||||
declare const http: FixtureHttpBinding;
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2339
|
||||
import type { Result } from "../../../src/contracts/result.ts";
|
||||
|
||||
export function invalidUnwrap(result: Result<number, string>): number {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
// expect: TS2741
|
||||
import { ROUTE_RUNTIME_CONTRACT } from "../../../src/features/installed-feature-contracts.ts";
|
||||
|
||||
type RouteId = keyof typeof ROUTE_RUNTIME_CONTRACT;
|
||||
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-application-input.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-application-output.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-async-overlay.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-diagnostics-port.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-direct-feature-composition.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-failure-kind.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-feature-capability-selection.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-feature-contribution-input.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-feature-input.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-http-operation-id.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-http-operation-input.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-http-route-id.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-http-wire-mapper.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-icon-button.tsx"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-image-cdn-resolve-signal.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-message-key.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-message-params.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-page-action.tsx"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-port-call.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-port-implementation.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-reference-operation.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-result-narrowing.ts"
|
||||
]
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
{
|
||||
"extends": "./tsconfig.base.json",
|
||||
"files": [
|
||||
"./invalid-route-runtime.ts"
|
||||
]
|
||||
}
|
||||
@@ -15,7 +15,7 @@ async function json<T>(relative: string): Promise<T> {
|
||||
const policy = (await json<{ surfaces: Surfaces }>("config/hosting/cache-policy.json")).surfaces;
|
||||
const fixtureHeaders = (
|
||||
await json<{ responses: Record<string, Record<string, string>> }>(
|
||||
"config/hosting/response-headers.fixture.json",
|
||||
"tests/fixtures/hosting/response-headers.json",
|
||||
)
|
||||
).responses;
|
||||
|
||||
|
||||
@@ -173,6 +173,9 @@ jobs:
|
||||
artifacts/security/supply-chain-coherence.json \\
|
||||
artifacts/security/supply-chain-verification.json \\
|
||||
artifacts/security/vulnerability-report.json \\
|
||||
config/schemas/artifacts/build-manifest.schema.json \\
|
||||
config/schemas/artifacts/dependency-inventory.schema.json \\
|
||||
config/schemas/artifacts/supply-chain-verification.schema.json \\
|
||||
config/security/dependency-baseline.approval.json \\
|
||||
config/security/dependency-baseline.json \\
|
||||
config/security/dependency-change-evidence.json \\
|
||||
@@ -180,9 +183,6 @@ jobs:
|
||||
config/security/secret-scan-policy.json \\
|
||||
config/security/vulnerability-exceptions.json \\
|
||||
config/security/vulnerability-policy.json \\
|
||||
schemas/artifacts/build-manifest.schema.json \\
|
||||
schemas/artifacts/dependency-inventory.schema.json \\
|
||||
schemas/artifacts/supply-chain-verification.schema.json \\
|
||||
scripts/contracts/release-artifacts.ts \\
|
||||
scripts/create-release-candidate.ts \\
|
||||
scripts/generate-supply-chain.ts \\
|
||||
|
||||
@@ -196,9 +196,9 @@ describe("CI gate contract", () => {
|
||||
).filter((gateId) => gateId !== "FE-GATE-016"),
|
||||
);
|
||||
expect(contract.jobs).toHaveLength(10);
|
||||
expect(contract.commands).toHaveLength(99);
|
||||
expect(contract.gates.reduce((total, gate) => total + gate.commandIds.length, 0)).toBe(103);
|
||||
expect(contract.commands.filter(({ expect }) => expect === "fail")).toHaveLength(30);
|
||||
expect(contract.commands).toHaveLength(76);
|
||||
expect(contract.gates.reduce((total, gate) => total + gate.commandIds.length, 0)).toBe(80);
|
||||
expect(contract.commands.filter(({ expect }) => expect === "fail")).toHaveLength(8);
|
||||
expect(contract.gates.reduce((total, gate) => total + gate.evidenceArtifactIds.length, 0)).toBe(83);
|
||||
expect(contract.artifacts).toHaveLength(105);
|
||||
expect(contract.stages).toHaveLength(5);
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user