Publish curated projectbrain source from 86d690c7579e368ce86b878b87bbeead9565ca20
This commit is contained in:
1 parent
5aa3e8d685
commit
471bd99c49
5 files changed
+2
-93
No files matched your search
@@ -1,31 +0,0 @@
|
||||
import { readFileSync } from "node:fs";
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
const readRepositoryFile = (path: string) =>
|
||||
readFileSync(new URL(`../../../${path}`, import.meta.url), "utf8");
|
||||
|
||||
describe("Auto Mode executor host contract", () => {
|
||||
it("keeps ordinary ChatGPT web chat as the only primary executor surface", () => {
|
||||
const productContract = readRepositoryFile("docs/UX_AUTONOMY_PRODUCT_CONTRACT.md");
|
||||
const operatingGuide = readRepositoryFile("docs/PROJECTBRAIN_CHATGPT_OPERATING_LAYER.md");
|
||||
|
||||
expect(productContract).toContain(
|
||||
"primary Auto Mode executor surface MUST be scheduled tasks in the ordinary ChatGPT web chat",
|
||||
);
|
||||
expect(productContract).toContain("Codex desktop or Codex CLI automations");
|
||||
expect(operatingGuide).toContain(
|
||||
"only supported primary executor surface is scheduled tasks in the ordinary ChatGPT **web chat**",
|
||||
);
|
||||
expect(productContract).toContain("Multiple such tasks MAY run concurrently");
|
||||
expect(operatingGuide).toContain("different projects concurrently");
|
||||
expect(operatingGuide).toContain(
|
||||
"Codex automations, Codex CLI, ChatGPT Work, local cron jobs and server-side OpenAI API calls MUST NOT schedule",
|
||||
);
|
||||
expect(productContract).toContain(
|
||||
"MUST NOT pause, disable, delete, reschedule, or otherwise mutate its own recurring ChatGPT task",
|
||||
);
|
||||
expect(operatingGuide).toContain(
|
||||
"MUST NOT pause, disable, delete or reschedule its own recurring ChatGPT web task",
|
||||
);
|
||||
});
|
||||
});
|
||||
@@ -1,15 +0,0 @@
|
||||
import { readFileSync } from "node:fs";
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
describe("release validation contract", () => {
|
||||
it("keeps mock and real browser smoke inside the deployment-authoritative full gate", () => {
|
||||
const workflow = readFileSync(new URL("../../../.gitea/workflows/managed-validation.yml", import.meta.url), "utf8");
|
||||
|
||||
expect(workflow).toContain("postgres:16");
|
||||
expect(workflow).toContain("TEST_DATABASE_URL");
|
||||
expect(workflow).toMatch(/\[\[\s+"\$\{profile\}"\s+==\s+(?:"full"|full)/);
|
||||
expect(workflow).toContain("playwright install --with-deps --force chromium chromium-headless-shell");
|
||||
expect(workflow).toContain("pnpm test:e2e");
|
||||
expect(workflow).toContain("pnpm test:e2e:real");
|
||||
});
|
||||
});
|
||||
@@ -1,30 +0,0 @@
|
||||
import { readdirSync, readFileSync } from "node:fs";
|
||||
import { join } from "node:path";
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
const workflowRoot = join(process.cwd(), ".gitea", "workflows");
|
||||
const workflowFiles = readdirSync(workflowRoot)
|
||||
.filter((name) => name.endsWith(".yml") || name.endsWith(".yaml"))
|
||||
.sort();
|
||||
|
||||
const workflowSource = (name: string) => readFileSync(join(workflowRoot, name), "utf8");
|
||||
|
||||
describe("runnerless production delivery policy", () => {
|
||||
it("keeps production mutation out of Gitea Actions", () => {
|
||||
expect(workflowFiles).not.toContain("unraid-deploy.yml");
|
||||
|
||||
for (const name of workflowFiles) {
|
||||
const source = workflowSource(name);
|
||||
expect(source, `${name} must not target the retired deployment runner`).not.toMatch(/runs-on:\s*unraid-deploy\b/);
|
||||
expect(source, `${name} must not execute the root deployment controller`).not.toMatch(/docker\s+exec\s+gitea-deploy-control/);
|
||||
expect(source, `${name} must not call the legacy deploy entrypoint`).not.toMatch(/deploy\.py\s+deploy\b/);
|
||||
}
|
||||
});
|
||||
|
||||
it("retains the exact validation context consumed by the runnerless controller", () => {
|
||||
const managedValidation = workflowSource("managed-validation.yml");
|
||||
expect(managedValidation).toContain("name: Managed validation");
|
||||
expect(managedValidation).toContain("branches: [main]");
|
||||
expect(managedValidation).toContain("name: full");
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user