From c2d0615b38a9616017137b2636a657e51eb64155 Mon Sep 17 00:00:00 2001 From: Muhammad Date: Wed, 13 Nov 2024 14:58:56 +0700 Subject: [PATCH] e2e test --- boilerplates/eslint/files/eslint.config.js | 2 ++ boilerplates/shared/files/tsconfig.json | 2 +- ...AMEWORK+tailwindcss.spec.ts => FRAMEWORK+CSS.spec.ts} | 9 ++++++++- 3 files changed, 11 insertions(+), 2 deletions(-) rename packages/tests/tests/{FRAMEWORK+tailwindcss.spec.ts => FRAMEWORK+CSS.spec.ts} (64%) diff --git a/boilerplates/eslint/files/eslint.config.js b/boilerplates/eslint/files/eslint.config.js index 61c1dcee0..e7636747b 100644 --- a/boilerplates/eslint/files/eslint.config.js +++ b/boilerplates/eslint/files/eslint.config.js @@ -19,6 +19,8 @@ export default tseslint.config( ".vercel/*", //# BATI.has("aws") "cdk.out/*", + //# BATI.has("panda-css") + "styled-system/", // JS files at the root of the project "*.js", "*.cjs", diff --git a/boilerplates/shared/files/tsconfig.json b/boilerplates/shared/files/tsconfig.json index b2193bace..3fe7c7df1 100644 --- a/boilerplates/shared/files/tsconfig.json +++ b/boilerplates/shared/files/tsconfig.json @@ -2,7 +2,7 @@ "compilerOptions": { "strict": true, "allowJs": true, - "checkJs": true, + "checkJs": false, "esModuleInterop": true, "forceConsistentCasingInFileNames": true, "resolveJsonModule": true, diff --git a/packages/tests/tests/FRAMEWORK+tailwindcss.spec.ts b/packages/tests/tests/FRAMEWORK+CSS.spec.ts similarity index 64% rename from packages/tests/tests/FRAMEWORK+tailwindcss.spec.ts rename to packages/tests/tests/FRAMEWORK+CSS.spec.ts index 91a4ee76b..512feb90c 100644 --- a/packages/tests/tests/FRAMEWORK+tailwindcss.spec.ts +++ b/packages/tests/tests/FRAMEWORK+CSS.spec.ts @@ -1,7 +1,9 @@ import { readFile } from "node:fs/promises"; import { describeBati } from "@batijs/tests-utils"; +import { existsSync } from "node:fs"; +import path from "node:path"; -export const matrix = [["solid", "react", "vue"], ["tailwindcss", "daisyui"], "eslint"]; +export const matrix = [["solid", "react", "vue"], ["tailwindcss", "daisyui", "panda-css"], "eslint"]; await describeBati(({ test, expect, fetch, context }) => { test("home", async () => { @@ -14,4 +16,9 @@ await describeBati(({ test, expect, fetch, context }) => { const content = await readFile("tailwind.config.ts", "utf-8"); expect(content.includes("daisyui")).toBe(context.flags.includes("daisyui")); }); + + test("panda-css", async () => { + expect(existsSync(path.join(process.cwd(), "panda.config.ts"))).toBe(true); + expect(existsSync(path.join(process.cwd(), "layouts", "panda.css"))).toBe(true); + }); });