fix(dev): consolidate generated cache directories
Quality / quality (ubuntu-latest) (push) Failing after 9m50s
Quality / quality (windows-latest) (push) Canceled after 0s

This commit is contained in:
2026-08-12 22:25:12 +05:30
parent e638c6be6a
commit b508b49058
8 changed files with 28 additions and 13 deletions
@@ -63,14 +63,14 @@ export default defineAuthz({ permissions: { "post:read": { title: "View posts" }
try {
expect(hasAuthzCatalog()).toBe(true);
expect(getAuthzCatalog().permissions.has("post:read")).toBe(true);
const cacheDir = join(appDir, "..", `.wrnexus-${process.pid}`);
const cacheDir = join(appDir, "..", ".wrnexus", "cache");
mkdirSync(cacheDir, { recursive: true });
writeFileSync(join(cacheDir, "generated.js"), "generated", "utf8");
expect(existsSync(cacheDir)).toBe(true);
} finally {
server.stop();
}
expect(existsSync(join(appDir, "..", `.wrnexus-${process.pid}`))).toBe(false);
expect(existsSync(join(appDir, "..", ".wrnexus", "cache"))).toBe(false);
});
test("an app with no app/authz declarations boots without throwing", async () => {