test: simplify dify ui browser test setup (#39028)

This commit is contained in:
yyh
2026-07-15 15:37:28 +00:00
committed by GitHub
parent 79662d49af
commit abb9972e19
6 changed files with 15 additions and 12 deletions
+2 -1
View File
@@ -9,7 +9,8 @@
"src/**/*.ts",
"src/**/*.tsx",
"vite.config.ts",
"vitest.config.ts"
"vitest.config.ts",
"vitest.setup.ts"
],
"exclude": ["node_modules", "dist", "storybook-static", "coverage"]
}
-1
View File
@@ -49,7 +49,6 @@ export default defineConfig({
provider: playwright(),
instances: [{ browser: 'chromium' }],
headless: true,
testerHtmlPath: './vitest.tester.html',
},
},
},
+6
View File
@@ -0,0 +1,6 @@
@import 'tailwindcss';
@import './src/styles/styles.css';
@plugin './src/plugins/icons.ts';
@source './src';
+4
View File
@@ -1,3 +1,7 @@
import './vitest.css'
document.documentElement.dataset.theme = 'light'
;(
globalThis as typeof globalThis & {
BASE_UI_ANIMATIONS_DISABLED: boolean
-10
View File
@@ -1,10 +0,0 @@
<!doctype html>
<html lang="en" data-theme="light">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="./.storybook/storybook.css" />
<title>Dify UI Tests</title>
</head>
<body></body>
</html>