Files
rea/tests/process-global/curatedWindowsLane.test.ts
T
morluto 4fbc501121 feat(native): add inspection primitives, dispatch traces and approved UI observation (#500)
* fix(hopper): normalize string-backed addresses and update verification

* feat(native): add inspection primitives, dispatch traces and approved UI observation

* test: prioritize real artifact E2E and captured golden regressions

* fix(process): queue observed output before reactive rendering actions

* test: prune redundant cases and strengthen boundary assertions

* fix(cli): route native value tracing through shared workflows

* test: replace synthetic success with real workflows and captured data

* fix(catalog): separate portable metadata from native host availability
2026-10-04 16:02:36 +08:00

42 lines
1.2 KiB
TypeScript

import { access, readFile } from "node:fs/promises";
import { join } from "node:path";
import { describe, expect, it } from "vitest";
import { parse } from "yaml";
const WORKFLOW = join(".github", "workflows", "ci.yml");
const curatedPaths = async (): Promise<string[]> => {
const workflow = parse(await readFile(WORKFLOW, "utf8")) as {
jobs?: Record<string, { steps?: { run?: string }[] }>;
};
const run = workflow.jobs?.["windows-curated"]?.steps
?.map((step) => step.run)
.find((value) => value?.includes("npx vitest run"));
expect(run, "expected a curated Windows vitest invocation").toBeDefined();
return (
run
?.split(/\s+/)
.filter((token) => token.endsWith(".test.ts"))
.sort() ?? []
);
};
const exists = async (path: string): Promise<boolean> =>
access(path).then(
() => true,
() => false,
);
describe("curated Windows test lane", () => {
it("references only test files that exist", async () => {
const paths = await curatedPaths();
expect(paths.length).toBeGreaterThan(0);
const missing = await Promise.all(
paths.map(async (path) => ((await exists(path)) ? undefined : path)),
);
expect(missing.filter((path) => path !== undefined)).toEqual([]);
}, 10_000);
});