mirror of
https://github.com/navikt/aksel.git
synced 2026-10-12 16:52:03 +00:00
33 lines
1.0 KiB
TypeScript
33 lines
1.0 KiB
TypeScript
import { storybookTest } from "@storybook/addon-vitest/vitest-plugin";
|
|
import { playwright } from "@vitest/browser-playwright";
|
|
import { defineConfig } from "vitest/config";
|
|
|
|
// More info at: https://storybook.js.org/docs/next/writing-tests/integrations/vitest-addon
|
|
export default defineConfig({
|
|
test: {
|
|
projects: [
|
|
{
|
|
extends: true,
|
|
plugins: [
|
|
// The plugin will run tests for the stories defined in your Storybook config
|
|
// See options at: https://storybook.js.org/docs/next/writing-tests/integrations/vitest-addon#storybooktest
|
|
storybookTest({
|
|
configDir: "./.storybook",
|
|
tags: { exclude: ["skip-test"], include: ["play-fn"] },
|
|
storybookScript: "yarn storybook --ci",
|
|
}),
|
|
],
|
|
test: {
|
|
name: "storybook",
|
|
browser: {
|
|
enabled: true,
|
|
headless: true,
|
|
provider: playwright(),
|
|
instances: [{ browser: "firefox" }],
|
|
},
|
|
},
|
|
},
|
|
],
|
|
},
|
|
});
|