chore: migrate to oxlint and oxfmt

Co-authored-by: Christoph Nakazawa <christoph.pojer@gmail.com>
This commit is contained in:
Peter Steinberger
2026-01-14 14:31:43 +00:00
parent 912ebffc63
commit c379191f80
1480 changed files with 28608 additions and 43547 deletions

View File

@@ -27,11 +27,7 @@ function extractCronChannels(schema: SchemaLike): string[] {
return channels;
}
const UI_FILES = [
"ui/src/ui/types.ts",
"ui/src/ui/ui-types.ts",
"ui/src/ui/views/cron.ts",
];
const UI_FILES = ["ui/src/ui/types.ts", "ui/src/ui/ui-types.ts", "ui/src/ui/views/cron.ts"];
const SWIFT_FILES = ["apps/macos/Sources/Clawdbot/GatewayConnection.swift"];
@@ -44,10 +40,7 @@ describe("cron protocol conformance", () => {
for (const relPath of UI_FILES) {
const content = await fs.readFile(path.join(cwd, relPath), "utf-8");
for (const channel of channels) {
expect(
content.includes(`"${channel}"`),
`${relPath} missing ${channel}`,
).toBe(true);
expect(content.includes(`"${channel}"`), `${relPath} missing ${channel}`).toBe(true);
}
}
@@ -55,20 +48,14 @@ describe("cron protocol conformance", () => {
const content = await fs.readFile(path.join(cwd, relPath), "utf-8");
for (const channel of channels) {
const pattern = new RegExp(`\\bcase\\s+${channel}\\b`);
expect(
pattern.test(content),
`${relPath} missing case ${channel}`,
).toBe(true);
expect(pattern.test(content), `${relPath} missing case ${channel}`).toBe(true);
}
}
});
it("cron status shape matches gateway fields in UI + Swift", async () => {
const cwd = process.cwd();
const uiTypes = await fs.readFile(
path.join(cwd, "ui/src/ui/types.ts"),
"utf-8",
);
const uiTypes = await fs.readFile(path.join(cwd, "ui/src/ui/types.ts"), "utf-8");
expect(uiTypes.includes("export type CronStatus")).toBe(true);
expect(uiTypes.includes("jobs:")).toBe(true);
expect(uiTypes.includes("jobCount")).toBe(false);