@nuxt/test-utils 3.9.0-alpha.3 → 3.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/e2e.d.mts +11 -5
- package/dist/e2e.d.ts +11 -5
- package/dist/e2e.mjs +11 -2
- package/dist/experimental.mjs +1 -1
- package/dist/module.mjs +5 -15
- package/dist/runtime/nuxt-root.d.ts +1 -1
- package/dist/runtime-utils/index.d.mts +3 -3
- package/dist/runtime-utils/index.d.ts +3 -3
- package/dist/runtime-utils/index.mjs +9 -6
- package/dist/shared/{test-utils.B1uaYm8K.mjs → test-utils.JYxxBhQl.mjs} +5 -3
- package/package.json +40 -32
package/dist/e2e.d.mts
CHANGED
|
@@ -8,7 +8,7 @@ declare function createBrowser(): Promise<void>;
|
|
|
8
8
|
declare function getBrowser(): Promise<Browser>;
|
|
9
9
|
declare function createPage(path?: string, options?: BrowserContextOptions): Promise<playwright_core.Page>;
|
|
10
10
|
|
|
11
|
-
type TestRunner = 'vitest' | 'jest';
|
|
11
|
+
type TestRunner = 'vitest' | 'jest' | 'cucumber';
|
|
12
12
|
interface TestOptions {
|
|
13
13
|
testDir: string;
|
|
14
14
|
fixture: string;
|
|
@@ -46,8 +46,8 @@ interface TestContext {
|
|
|
46
46
|
interface TestHooks {
|
|
47
47
|
beforeEach: () => void;
|
|
48
48
|
afterEach: () => void;
|
|
49
|
-
afterAll: () => void
|
|
50
|
-
setup: () => void
|
|
49
|
+
afterAll: () => Promise<void>;
|
|
50
|
+
setup: () => Promise<void>;
|
|
51
51
|
ctx: TestContext;
|
|
52
52
|
}
|
|
53
53
|
|
|
@@ -65,17 +65,23 @@ declare function mockLogger(): Record<string, Function>;
|
|
|
65
65
|
declare function loadFixture(): Promise<void>;
|
|
66
66
|
declare function buildFixture(): Promise<void>;
|
|
67
67
|
|
|
68
|
-
|
|
68
|
+
interface StartServerOptions {
|
|
69
|
+
env?: Record<string, unknown>;
|
|
70
|
+
}
|
|
71
|
+
declare function startServer(options?: StartServerOptions): Promise<void>;
|
|
69
72
|
declare function stopServer(): Promise<void>;
|
|
70
73
|
declare function fetch(path: string, options?: any): Promise<Response>;
|
|
71
74
|
declare function $fetch(path: string, options?: FetchOptions): Promise<any>;
|
|
72
75
|
declare function url(path: string): string;
|
|
73
76
|
|
|
77
|
+
declare function setupCucumber(hooks: TestHooks): Promise<void>;
|
|
78
|
+
|
|
74
79
|
declare function setupJest(hooks: TestHooks): Promise<void>;
|
|
75
80
|
|
|
76
81
|
declare function setupVitest(hooks: TestHooks): Promise<void>;
|
|
77
82
|
|
|
78
83
|
declare const setupMaps: {
|
|
84
|
+
cucumber: typeof setupCucumber;
|
|
79
85
|
jest: typeof setupJest;
|
|
80
86
|
vitest: typeof setupVitest;
|
|
81
87
|
};
|
|
@@ -91,4 +97,4 @@ interface RunTestOptions {
|
|
|
91
97
|
}
|
|
92
98
|
declare function runTests(opts: RunTestOptions): Promise<void>;
|
|
93
99
|
|
|
94
|
-
export { $fetch, type RunTestOptions, type TestContext, type TestHooks, type TestOptions, type TestRunner, buildFixture, createBrowser, createPage, createTest, createTestContext, exposeContextToEnv, fetch, getBrowser, isDev, loadFixture, mockFn, mockLogger, recoverContextFromEnv, runTests, setTestContext, setup, setupMaps, startServer, stopServer, url, useTestContext };
|
|
100
|
+
export { $fetch, type RunTestOptions, type StartServerOptions, type TestContext, type TestHooks, type TestOptions, type TestRunner, buildFixture, createBrowser, createPage, createTest, createTestContext, exposeContextToEnv, fetch, getBrowser, isDev, loadFixture, mockFn, mockLogger, recoverContextFromEnv, runTests, setTestContext, setup, setupMaps, startServer, stopServer, url, useTestContext };
|
package/dist/e2e.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ declare function createBrowser(): Promise<void>;
|
|
|
8
8
|
declare function getBrowser(): Promise<Browser>;
|
|
9
9
|
declare function createPage(path?: string, options?: BrowserContextOptions): Promise<playwright_core.Page>;
|
|
10
10
|
|
|
11
|
-
type TestRunner = 'vitest' | 'jest';
|
|
11
|
+
type TestRunner = 'vitest' | 'jest' | 'cucumber';
|
|
12
12
|
interface TestOptions {
|
|
13
13
|
testDir: string;
|
|
14
14
|
fixture: string;
|
|
@@ -46,8 +46,8 @@ interface TestContext {
|
|
|
46
46
|
interface TestHooks {
|
|
47
47
|
beforeEach: () => void;
|
|
48
48
|
afterEach: () => void;
|
|
49
|
-
afterAll: () => void
|
|
50
|
-
setup: () => void
|
|
49
|
+
afterAll: () => Promise<void>;
|
|
50
|
+
setup: () => Promise<void>;
|
|
51
51
|
ctx: TestContext;
|
|
52
52
|
}
|
|
53
53
|
|
|
@@ -65,17 +65,23 @@ declare function mockLogger(): Record<string, Function>;
|
|
|
65
65
|
declare function loadFixture(): Promise<void>;
|
|
66
66
|
declare function buildFixture(): Promise<void>;
|
|
67
67
|
|
|
68
|
-
|
|
68
|
+
interface StartServerOptions {
|
|
69
|
+
env?: Record<string, unknown>;
|
|
70
|
+
}
|
|
71
|
+
declare function startServer(options?: StartServerOptions): Promise<void>;
|
|
69
72
|
declare function stopServer(): Promise<void>;
|
|
70
73
|
declare function fetch(path: string, options?: any): Promise<Response>;
|
|
71
74
|
declare function $fetch(path: string, options?: FetchOptions): Promise<any>;
|
|
72
75
|
declare function url(path: string): string;
|
|
73
76
|
|
|
77
|
+
declare function setupCucumber(hooks: TestHooks): Promise<void>;
|
|
78
|
+
|
|
74
79
|
declare function setupJest(hooks: TestHooks): Promise<void>;
|
|
75
80
|
|
|
76
81
|
declare function setupVitest(hooks: TestHooks): Promise<void>;
|
|
77
82
|
|
|
78
83
|
declare const setupMaps: {
|
|
84
|
+
cucumber: typeof setupCucumber;
|
|
79
85
|
jest: typeof setupJest;
|
|
80
86
|
vitest: typeof setupVitest;
|
|
81
87
|
};
|
|
@@ -91,4 +97,4 @@ interface RunTestOptions {
|
|
|
91
97
|
}
|
|
92
98
|
declare function runTests(opts: RunTestOptions): Promise<void>;
|
|
93
99
|
|
|
94
|
-
export { $fetch, type RunTestOptions, type TestContext, type TestHooks, type TestOptions, type TestRunner, buildFixture, createBrowser, createPage, createTest, createTestContext, exposeContextToEnv, fetch, getBrowser, isDev, loadFixture, mockFn, mockLogger, recoverContextFromEnv, runTests, setTestContext, setup, setupMaps, startServer, stopServer, url, useTestContext };
|
|
100
|
+
export { $fetch, type RunTestOptions, type StartServerOptions, type TestContext, type TestHooks, type TestOptions, type TestRunner, buildFixture, createBrowser, createPage, createTest, createTestContext, exposeContextToEnv, fetch, getBrowser, isDev, loadFixture, mockFn, mockLogger, recoverContextFromEnv, runTests, setTestContext, setup, setupMaps, startServer, stopServer, url, useTestContext };
|
package/dist/e2e.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { u as useTestContext, a as url, c as createTestContext, s as setTestContext, b as stopServer, d as startServer } from './shared/test-utils.
|
|
2
|
-
export { $ as $fetch, e as exposeContextToEnv, f as fetch, i as isDev, r as recoverContextFromEnv } from './shared/test-utils.
|
|
1
|
+
import { u as useTestContext, a as url, c as createTestContext, s as setTestContext, b as stopServer, d as startServer } from './shared/test-utils.JYxxBhQl.mjs';
|
|
2
|
+
export { $ as $fetch, e as exposeContextToEnv, f as fetch, i as isDev, r as recoverContextFromEnv } from './shared/test-utils.JYxxBhQl.mjs';
|
|
3
3
|
import { consola } from 'consola';
|
|
4
4
|
import { existsSync, promises } from 'node:fs';
|
|
5
5
|
import { resolve } from 'node:path';
|
|
@@ -114,6 +114,14 @@ async function buildFixture() {
|
|
|
114
114
|
kit.logger.level = prevLevel;
|
|
115
115
|
}
|
|
116
116
|
|
|
117
|
+
async function setupCucumber(hooks) {
|
|
118
|
+
const { After, AfterAll, Before, BeforeAll } = await import('@cucumber/cucumber');
|
|
119
|
+
BeforeAll({ timeout: hooks.ctx.options.setupTimeout }, hooks.setup);
|
|
120
|
+
Before(hooks.beforeEach);
|
|
121
|
+
After(hooks.afterEach);
|
|
122
|
+
AfterAll(hooks.afterAll);
|
|
123
|
+
}
|
|
124
|
+
|
|
117
125
|
async function setupJest(hooks) {
|
|
118
126
|
const { jest, test, beforeEach, afterAll, afterEach } = await import('@jest/globals');
|
|
119
127
|
hooks.ctx.mockFn = jest.fn;
|
|
@@ -133,6 +141,7 @@ async function setupVitest(hooks) {
|
|
|
133
141
|
}
|
|
134
142
|
|
|
135
143
|
const setupMaps = {
|
|
144
|
+
cucumber: setupCucumber,
|
|
136
145
|
jest: setupJest,
|
|
137
146
|
vitest: setupVitest
|
|
138
147
|
};
|
package/dist/experimental.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { resolve } from 'pathe';
|
|
2
2
|
import { stringifyQuery } from 'ufo';
|
|
3
|
-
import { $ as $fetch, u as useTestContext } from './shared/test-utils.
|
|
3
|
+
import { $ as $fetch, u as useTestContext } from './shared/test-utils.JYxxBhQl.mjs';
|
|
4
4
|
import 'execa';
|
|
5
5
|
import 'get-port-please';
|
|
6
6
|
import 'ofetch';
|
package/dist/module.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { pathToFileURL } from 'node:url';
|
|
2
|
-
import {
|
|
2
|
+
import { useNuxt, resolveIgnorePatterns, addVitePlugin, defineNuxtModule, createResolver, resolvePath, logger } from '@nuxt/kit';
|
|
3
3
|
import { mergeConfig } from 'vite';
|
|
4
4
|
import { getPort } from 'get-port-please';
|
|
5
5
|
import { h } from 'vue';
|
|
@@ -9,7 +9,6 @@ import { defu } from 'defu';
|
|
|
9
9
|
import { getVitestConfigFromNuxt } from './config.mjs';
|
|
10
10
|
import { walk } from 'estree-walker';
|
|
11
11
|
import MagicString from 'magic-string';
|
|
12
|
-
import { normalize, resolve } from 'node:path';
|
|
13
12
|
import { createUnplugin } from 'unplugin';
|
|
14
13
|
import { readFileSync } from 'node:fs';
|
|
15
14
|
import { extname, join, dirname } from 'pathe';
|
|
@@ -23,10 +22,7 @@ const HELPER_MOCK_COMPONENT = "mockComponent";
|
|
|
23
22
|
const HELPER_MOCK_HOIST = "__NUXT_VITEST_MOCKS";
|
|
24
23
|
const HELPERS_NAME = [HELPER_MOCK_IMPORT, HELPER_MOCK_COMPONENT];
|
|
25
24
|
const createMockPlugin = (ctx) => createUnplugin(() => {
|
|
26
|
-
let resolvedFirstSetupFile = null;
|
|
27
25
|
function transform(code, id) {
|
|
28
|
-
const isFirstSetupFile = normalize(id) === resolvedFirstSetupFile;
|
|
29
|
-
const shouldPrependMockHoist = resolvedFirstSetupFile ? isFirstSetupFile : true;
|
|
30
26
|
if (!HELPERS_NAME.some((n) => code.includes(n)))
|
|
31
27
|
return;
|
|
32
28
|
if (id.includes("/node_modules/"))
|
|
@@ -205,12 +201,10 @@ const createMockPlugin = (ctx) => createUnplugin(() => {
|
|
|
205
201
|
s.prepend(`import {vi} from "vitest";
|
|
206
202
|
`);
|
|
207
203
|
s.appendLeft(insertionPoint, mockLines.join("\n") + "\n");
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
s.append(`
|
|
204
|
+
importPathsList.forEach((p) => {
|
|
205
|
+
s.append(`
|
|
211
206
|
import ${JSON.stringify(p)};`);
|
|
212
|
-
|
|
213
|
-
}
|
|
207
|
+
});
|
|
214
208
|
return {
|
|
215
209
|
code: s.toString(),
|
|
216
210
|
map: s.generateMap()
|
|
@@ -223,10 +217,6 @@ const createMockPlugin = (ctx) => createUnplugin(() => {
|
|
|
223
217
|
transform,
|
|
224
218
|
// Place Vitest's mock plugin after all Nuxt plugins
|
|
225
219
|
async configResolved(config) {
|
|
226
|
-
const firstSetupFile = Array.isArray(config.test?.setupFiles) ? config.test.setupFiles.find((p) => !p.includes("runtime/entry")) : config.test?.setupFiles;
|
|
227
|
-
if (firstSetupFile) {
|
|
228
|
-
resolvedFirstSetupFile = await resolvePath(normalize(resolve(firstSetupFile)));
|
|
229
|
-
}
|
|
230
220
|
const plugins = config.plugins || [];
|
|
231
221
|
const vitestPlugins = plugins.filter((p) => (p.name === "vite:mocks" || p.name.startsWith("vitest:")) && (p.enforce || p.order) === "post");
|
|
232
222
|
const lastNuxt = findLastIndex(
|
|
@@ -330,7 +320,7 @@ const vitePluginBlocklist = ["vite-plugin-vue-inspector", "vite-plugin-vue-inspe
|
|
|
330
320
|
const module = defineNuxtModule({
|
|
331
321
|
meta: {
|
|
332
322
|
name: "@nuxt/test-utils",
|
|
333
|
-
configKey: "
|
|
323
|
+
configKey: "testUtils"
|
|
334
324
|
},
|
|
335
325
|
defaults: {
|
|
336
326
|
startOnBoot: false,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<{}, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
2
2
|
[key: string]: any;
|
|
3
|
-
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").
|
|
3
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}, {}>;
|
|
4
4
|
export default _default;
|
|
@@ -19,7 +19,7 @@ type OptionalFunction<T> = T | (() => Awaitable<T>);
|
|
|
19
19
|
* test: "test-field"
|
|
20
20
|
* })
|
|
21
21
|
* ```
|
|
22
|
-
* @see https://
|
|
22
|
+
* @see https://nuxt.com/docs/getting-started/testing#registerendpoint
|
|
23
23
|
*/
|
|
24
24
|
declare function registerEndpoint(url: string, options: EventHandler | {
|
|
25
25
|
handler: EventHandler;
|
|
@@ -39,7 +39,7 @@ declare function registerEndpoint(url: string, options: EventHandler | {
|
|
|
39
39
|
* }
|
|
40
40
|
* })
|
|
41
41
|
* ```
|
|
42
|
-
* @see https://
|
|
42
|
+
* @see https://nuxt.com/docs/getting-started/testing#mocknuxtimport
|
|
43
43
|
*/
|
|
44
44
|
declare function mockNuxtImport<T = any>(_name: string, _factory: () => T | Promise<T>): void;
|
|
45
45
|
/**
|
|
@@ -72,7 +72,7 @@ declare function mockNuxtImport<T = any>(_name: string, _factory: () => T | Prom
|
|
|
72
72
|
* // or you can use SFC for redirecting to a mock component
|
|
73
73
|
* mockComponent('MyComponent', () => import('./MockComponent.vue'))
|
|
74
74
|
* ```
|
|
75
|
-
* @see https://
|
|
75
|
+
* @see https://nuxt.com/docs/getting-started/testing#mockcomponent
|
|
76
76
|
*/
|
|
77
77
|
declare function mockComponent<Props, RawBindings = object>(path: string, setup: OptionalFunction<(props: Readonly<Props>, ctx: SetupContext) => RawBindings | RenderFunction>): void;
|
|
78
78
|
declare function mockComponent<Props = {}, RawBindings = {}, D = {}, C extends ComputedOptions = {}, M extends MethodOptions = {}, Mixin extends ComponentOptionsMixin = ComponentOptionsMixin, Extends extends ComponentOptionsMixin = ComponentOptionsMixin, E extends EmitsOptions = {}, EE extends string = string, I extends ComponentInjectOptions = {}, II extends string = string>(path: string, options: OptionalFunction<ComponentOptionsWithoutProps<Props, RawBindings, D, C, M, Mixin, Extends, E, EE, I, II>>): void;
|
|
@@ -19,7 +19,7 @@ type OptionalFunction<T> = T | (() => Awaitable<T>);
|
|
|
19
19
|
* test: "test-field"
|
|
20
20
|
* })
|
|
21
21
|
* ```
|
|
22
|
-
* @see https://
|
|
22
|
+
* @see https://nuxt.com/docs/getting-started/testing#registerendpoint
|
|
23
23
|
*/
|
|
24
24
|
declare function registerEndpoint(url: string, options: EventHandler | {
|
|
25
25
|
handler: EventHandler;
|
|
@@ -39,7 +39,7 @@ declare function registerEndpoint(url: string, options: EventHandler | {
|
|
|
39
39
|
* }
|
|
40
40
|
* })
|
|
41
41
|
* ```
|
|
42
|
-
* @see https://
|
|
42
|
+
* @see https://nuxt.com/docs/getting-started/testing#mocknuxtimport
|
|
43
43
|
*/
|
|
44
44
|
declare function mockNuxtImport<T = any>(_name: string, _factory: () => T | Promise<T>): void;
|
|
45
45
|
/**
|
|
@@ -72,7 +72,7 @@ declare function mockNuxtImport<T = any>(_name: string, _factory: () => T | Prom
|
|
|
72
72
|
* // or you can use SFC for redirecting to a mock component
|
|
73
73
|
* mockComponent('MyComponent', () => import('./MockComponent.vue'))
|
|
74
74
|
* ```
|
|
75
|
-
* @see https://
|
|
75
|
+
* @see https://nuxt.com/docs/getting-started/testing#mockcomponent
|
|
76
76
|
*/
|
|
77
77
|
declare function mockComponent<Props, RawBindings = object>(path: string, setup: OptionalFunction<(props: Readonly<Props>, ctx: SetupContext) => RawBindings | RenderFunction>): void;
|
|
78
78
|
declare function mockComponent<Props = {}, RawBindings = {}, D = {}, C extends ComputedOptions = {}, M extends MethodOptions = {}, Mixin extends ComponentOptionsMixin = ComponentOptionsMixin, Extends extends ComponentOptionsMixin = ComponentOptionsMixin, E extends EmitsOptions = {}, EE extends string = string, I extends ComponentInjectOptions = {}, II extends string = string>(path: string, options: OptionalFunction<ComponentOptionsWithoutProps<Props, RawBindings, D, C, M, Mixin, Extends, E, EE, I, II>>): void;
|
|
@@ -22,19 +22,22 @@ function registerEndpoint(url, options) {
|
|
|
22
22
|
}
|
|
23
23
|
function mockNuxtImport(_name, _factory) {
|
|
24
24
|
throw new Error(
|
|
25
|
-
"mockNuxtImport() is a macro and it did not get transpiled
|
|
25
|
+
"mockNuxtImport() is a macro and it did not get transpiled. This may be an internal bug of @nuxt/test-utils."
|
|
26
26
|
);
|
|
27
27
|
}
|
|
28
28
|
function mockComponent(_path, _component) {
|
|
29
29
|
throw new Error(
|
|
30
|
-
"mockComponent() is a macro and it did not get transpiled
|
|
30
|
+
"mockComponent() is a macro and it did not get transpiled. This may be an internal bug of @nuxt/test-utils."
|
|
31
31
|
);
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
const RouterLink = defineComponent({
|
|
35
35
|
functional: true,
|
|
36
36
|
props: {
|
|
37
|
-
to:
|
|
37
|
+
to: {
|
|
38
|
+
type: [String, Object],
|
|
39
|
+
required: true
|
|
40
|
+
},
|
|
38
41
|
custom: Boolean,
|
|
39
42
|
replace: Boolean,
|
|
40
43
|
// Not implemented
|
|
@@ -46,11 +49,11 @@ const RouterLink = defineComponent({
|
|
|
46
49
|
const navigate = () => {
|
|
47
50
|
};
|
|
48
51
|
return () => {
|
|
49
|
-
const route =
|
|
50
|
-
return props.custom ? slots.default?.({ href:
|
|
52
|
+
const route = useRouter().resolve(props.to);
|
|
53
|
+
return props.custom ? slots.default?.({ href: route.href, navigate, route }) : h(
|
|
51
54
|
"a",
|
|
52
55
|
{
|
|
53
|
-
href:
|
|
56
|
+
href: route.href,
|
|
54
57
|
onClick: (e) => {
|
|
55
58
|
e.preventDefault();
|
|
56
59
|
return navigate();
|
|
@@ -53,7 +53,7 @@ function exposeContextToEnv() {
|
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
const kit = _kit.default || _kit;
|
|
56
|
-
async function startServer() {
|
|
56
|
+
async function startServer(options = {}) {
|
|
57
57
|
const ctx = useTestContext();
|
|
58
58
|
await stopServer();
|
|
59
59
|
const host = "127.0.0.1";
|
|
@@ -70,7 +70,8 @@ async function startServer() {
|
|
|
70
70
|
// Used by internal _dev command
|
|
71
71
|
PORT: String(port),
|
|
72
72
|
HOST: host,
|
|
73
|
-
NODE_ENV: "development"
|
|
73
|
+
NODE_ENV: "development",
|
|
74
|
+
...options.env
|
|
74
75
|
}
|
|
75
76
|
});
|
|
76
77
|
await waitForPort(port, { retries: 32, host }).catch(() => {
|
|
@@ -98,7 +99,8 @@ async function startServer() {
|
|
|
98
99
|
...process.env,
|
|
99
100
|
PORT: String(port),
|
|
100
101
|
HOST: host,
|
|
101
|
-
NODE_ENV: "test"
|
|
102
|
+
NODE_ENV: "test",
|
|
103
|
+
...options.env
|
|
102
104
|
}
|
|
103
105
|
});
|
|
104
106
|
await waitForPort(port, { retries: 20, host });
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuxt/test-utils",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.10.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/nuxt/test-utils.git"
|
|
@@ -28,67 +28,69 @@
|
|
|
28
28
|
"vitest-environment.d.ts"
|
|
29
29
|
],
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@nuxt/kit": "^3.
|
|
32
|
-
"@nuxt/schema": "^3.
|
|
33
|
-
"c12": "^1.
|
|
31
|
+
"@nuxt/kit": "^3.9.3",
|
|
32
|
+
"@nuxt/schema": "^3.9.3",
|
|
33
|
+
"c12": "^1.6.1",
|
|
34
34
|
"consola": "^3.2.3",
|
|
35
|
-
"defu": "^6.1.
|
|
35
|
+
"defu": "^6.1.4",
|
|
36
36
|
"destr": "^2.0.2",
|
|
37
37
|
"estree-walker": "^3.0.3",
|
|
38
38
|
"execa": "^8.0.1",
|
|
39
|
-
"fake-indexeddb": "^5.0.
|
|
40
|
-
"get-port-please": "^3.1.
|
|
39
|
+
"fake-indexeddb": "^5.0.2",
|
|
40
|
+
"get-port-please": "^3.1.2",
|
|
41
41
|
"local-pkg": "^0.5.0",
|
|
42
42
|
"magic-string": "^0.30.5",
|
|
43
|
-
"node-fetch-native": "^1.
|
|
43
|
+
"node-fetch-native": "^1.6.1",
|
|
44
44
|
"ofetch": "^1.3.3",
|
|
45
|
-
"pathe": "^1.1.
|
|
45
|
+
"pathe": "^1.1.2",
|
|
46
46
|
"perfect-debounce": "^1.0.0",
|
|
47
47
|
"radix3": "^1.1.0",
|
|
48
|
-
"scule": "^1.
|
|
49
|
-
"std-env": "^3.
|
|
48
|
+
"scule": "^1.2.0",
|
|
49
|
+
"std-env": "^3.7.0",
|
|
50
50
|
"ufo": "^1.3.2",
|
|
51
|
-
"unenv": "^1.
|
|
52
|
-
"unplugin": "^1.
|
|
53
|
-
"vitest-environment-nuxt": "1.0.0
|
|
51
|
+
"unenv": "^1.9.0",
|
|
52
|
+
"unplugin": "^1.6.0",
|
|
53
|
+
"vitest-environment-nuxt": "^1.0.0"
|
|
54
54
|
},
|
|
55
55
|
"devDependencies": {
|
|
56
|
+
"@cucumber/cucumber": "10.3.1",
|
|
56
57
|
"@jest/globals": "29.7.0",
|
|
57
|
-
"@nuxt/devtools": "1.0.
|
|
58
|
+
"@nuxt/devtools": "1.0.8",
|
|
58
59
|
"@nuxt/eslint-config": "0.2.0",
|
|
59
|
-
"@nuxt/module-builder": "0.5.
|
|
60
|
+
"@nuxt/module-builder": "0.5.5",
|
|
60
61
|
"@testing-library/vue": "8.0.1",
|
|
61
62
|
"@types/estree": "1.0.5",
|
|
62
63
|
"@types/jsdom": "21.1.6",
|
|
63
64
|
"@types/semver": "7.5.6",
|
|
64
|
-
"@vitest/ui": "1.
|
|
65
|
+
"@vitest/ui": "1.1.1",
|
|
65
66
|
"@vue/test-utils": "2.4.3",
|
|
66
67
|
"changelogen": "0.5.5",
|
|
67
68
|
"eslint": "8.56.0",
|
|
68
69
|
"eslint-plugin-import": "2.29.1",
|
|
69
|
-
"eslint-plugin-jsdoc": "
|
|
70
|
+
"eslint-plugin-jsdoc": "48.0.2",
|
|
70
71
|
"eslint-plugin-no-only-tests": "3.1.0",
|
|
71
|
-
"eslint-plugin-unicorn": "
|
|
72
|
-
"h3": "1.
|
|
72
|
+
"eslint-plugin-unicorn": "50.0.1",
|
|
73
|
+
"h3": "1.10.0",
|
|
73
74
|
"jiti": "1.21.0",
|
|
74
|
-
"nuxt": "3.
|
|
75
|
-
"playwright-core": "1.
|
|
76
|
-
"rollup": "4.9.
|
|
75
|
+
"nuxt": "3.9.3",
|
|
76
|
+
"playwright-core": "1.41.0",
|
|
77
|
+
"rollup": "4.9.5",
|
|
77
78
|
"semver": "7.5.4",
|
|
78
79
|
"unbuild": "latest",
|
|
79
|
-
"unimport": "3.
|
|
80
|
-
"vite": "5.0.
|
|
81
|
-
"vitest": "
|
|
80
|
+
"unimport": "3.7.1",
|
|
81
|
+
"vite": "5.0.11",
|
|
82
|
+
"vitest": "1.1.1",
|
|
82
83
|
"vue-router": "4.2.5",
|
|
83
|
-
"vue-tsc": "1.8.
|
|
84
|
+
"vue-tsc": "1.8.27"
|
|
84
85
|
},
|
|
85
86
|
"peerDependencies": {
|
|
87
|
+
"@cucumber/cucumber": "^10.3.1",
|
|
86
88
|
"@jest/globals": "^29.5.0",
|
|
87
89
|
"@testing-library/vue": "^7.0.0 || ^8.0.1",
|
|
88
90
|
"@vitest/ui": "^0.34.6 || ^1.0.0",
|
|
89
91
|
"@vue/test-utils": "^2.4.2",
|
|
90
92
|
"h3": "*",
|
|
91
|
-
"happy-dom": "^9.10.9 || ^10.0.0 || ^11.0.0 || ^12.0.0",
|
|
93
|
+
"happy-dom": "^9.10.9 || ^10.0.0 || ^11.0.0 || ^12.0.0 || ^13.0.0",
|
|
92
94
|
"jsdom": "^22.0.0 || ^23.0.0",
|
|
93
95
|
"playwright-core": "^1.34.3",
|
|
94
96
|
"vite": "*",
|
|
@@ -97,6 +99,9 @@
|
|
|
97
99
|
"vue-router": "^4.0.0"
|
|
98
100
|
},
|
|
99
101
|
"peerDependenciesMeta": {
|
|
102
|
+
"@cucumber/cucumber": {
|
|
103
|
+
"optional": true
|
|
104
|
+
},
|
|
100
105
|
"@testing-library/vue": {
|
|
101
106
|
"optional": true
|
|
102
107
|
},
|
|
@@ -123,18 +128,21 @@
|
|
|
123
128
|
}
|
|
124
129
|
},
|
|
125
130
|
"resolutions": {
|
|
131
|
+
"@nuxt/schema": "^3.9.3",
|
|
132
|
+
"@nuxt/kit": "^3.9.3",
|
|
126
133
|
"@nuxt/test-utils": "workspace:*",
|
|
127
|
-
"rollup": "4.9.
|
|
128
|
-
"vite": "5.0.
|
|
134
|
+
"rollup": "4.9.5",
|
|
135
|
+
"vite": "5.0.11",
|
|
136
|
+
"vue": "^3.4.14"
|
|
129
137
|
},
|
|
130
138
|
"engines": {
|
|
131
139
|
"node": "^14.18.0 || >=16.10.0"
|
|
132
140
|
},
|
|
133
|
-
"packageManager": "pnpm@8.
|
|
141
|
+
"packageManager": "pnpm@8.14.1",
|
|
134
142
|
"scripts": {
|
|
135
143
|
"lint": "eslint --ext .vue,.ts,.js,.mjs .",
|
|
136
144
|
"lint:fix": "eslint --ext .vue,.ts,.js,.mjs . --fix",
|
|
137
|
-
"test:examples": "pnpm -r test",
|
|
145
|
+
"test:examples": "pnpm -r test --filter !nuxt-app-cucumber && pnpm -r test --filter nuxt-app-cucumber",
|
|
138
146
|
"test:types": "vue-tsc --noEmit",
|
|
139
147
|
"test:unit": "vitest test/unit --run",
|
|
140
148
|
"dev:prepare": "nuxi prepare && unbuild --stub && pnpm -r dev:prepare",
|