@testforgejs/vue-test-plugin-router 1.0.0-beta.3 → 1.0.0-beta.4
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/index.d.cts +29 -7
- package/dist/index.d.ts +29 -7
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -1,19 +1,38 @@
|
|
|
1
1
|
import { RouterOptions, Router } from 'vue-router';
|
|
2
2
|
import { PluginControlOptions, PluginModuleWithDefaults } from '@testforgejs/vue-test-core';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Stable TestForge identifier for the managed Vue Router plugin.
|
|
6
|
+
*
|
|
7
|
+
* Use this identifier when declaring Router configuration
|
|
8
|
+
* in presets and other plugin-aware TestForge APIs.
|
|
9
|
+
*/
|
|
4
10
|
declare const ROUTER_PLUGIN_NAME: "router";
|
|
5
11
|
|
|
6
12
|
/**
|
|
7
13
|
* Configuration options for the Vue Router test plugin.
|
|
8
14
|
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
15
|
+
* Combines standard Vue Router configuration (`RouterOptions` from `vue-router`)
|
|
16
|
+
* with TestForge plugin control options.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* Configure the managed Vue Router plugin for a component test:
|
|
11
20
|
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
21
|
+
* ```ts
|
|
22
|
+
* factory({}, {
|
|
23
|
+
* plugins: {
|
|
24
|
+
* router: {
|
|
25
|
+
* history: createMemoryHistory(),
|
|
26
|
+
* routes: [],
|
|
27
|
+
* },
|
|
28
|
+
* },
|
|
29
|
+
* });
|
|
30
|
+
* ```
|
|
31
|
+
*
|
|
32
|
+
* @see `RouterOptions` from `vue-router` for configuring routes and history.
|
|
33
|
+
* @see `PluginControlOptions` from `@testforgejs/vue-test-core` for instance capturing and exposure mechanisms.
|
|
14
34
|
*/
|
|
15
|
-
|
|
16
|
-
}
|
|
35
|
+
type VueTestRouterOptions = RouterOptions & PluginControlOptions<Router>;
|
|
17
36
|
|
|
18
37
|
/**
|
|
19
38
|
* Extending TestForge kernel types for Vue Router integration.
|
|
@@ -49,7 +68,10 @@ declare module "@testforgejs/vue-test-core" {
|
|
|
49
68
|
}
|
|
50
69
|
|
|
51
70
|
/**
|
|
52
|
-
*
|
|
71
|
+
* Managed Vue Router plugin module for TestForge.
|
|
72
|
+
*
|
|
73
|
+
* Provides the runtime definition for creating Vue Router instances
|
|
74
|
+
* and exposes the default configuration used by TestForge-managed presets.
|
|
53
75
|
*/
|
|
54
76
|
declare const routerPlugin: PluginModuleWithDefaults<Router, VueTestRouterOptions>;
|
|
55
77
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,19 +1,38 @@
|
|
|
1
1
|
import { RouterOptions, Router } from 'vue-router';
|
|
2
2
|
import { PluginControlOptions, PluginModuleWithDefaults } from '@testforgejs/vue-test-core';
|
|
3
3
|
|
|
4
|
+
/**
|
|
5
|
+
* Stable TestForge identifier for the managed Vue Router plugin.
|
|
6
|
+
*
|
|
7
|
+
* Use this identifier when declaring Router configuration
|
|
8
|
+
* in presets and other plugin-aware TestForge APIs.
|
|
9
|
+
*/
|
|
4
10
|
declare const ROUTER_PLUGIN_NAME: "router";
|
|
5
11
|
|
|
6
12
|
/**
|
|
7
13
|
* Configuration options for the Vue Router test plugin.
|
|
8
14
|
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
15
|
+
* Combines standard Vue Router configuration (`RouterOptions` from `vue-router`)
|
|
16
|
+
* with TestForge plugin control options.
|
|
17
|
+
*
|
|
18
|
+
* @example
|
|
19
|
+
* Configure the managed Vue Router plugin for a component test:
|
|
11
20
|
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
21
|
+
* ```ts
|
|
22
|
+
* factory({}, {
|
|
23
|
+
* plugins: {
|
|
24
|
+
* router: {
|
|
25
|
+
* history: createMemoryHistory(),
|
|
26
|
+
* routes: [],
|
|
27
|
+
* },
|
|
28
|
+
* },
|
|
29
|
+
* });
|
|
30
|
+
* ```
|
|
31
|
+
*
|
|
32
|
+
* @see `RouterOptions` from `vue-router` for configuring routes and history.
|
|
33
|
+
* @see `PluginControlOptions` from `@testforgejs/vue-test-core` for instance capturing and exposure mechanisms.
|
|
14
34
|
*/
|
|
15
|
-
|
|
16
|
-
}
|
|
35
|
+
type VueTestRouterOptions = RouterOptions & PluginControlOptions<Router>;
|
|
17
36
|
|
|
18
37
|
/**
|
|
19
38
|
* Extending TestForge kernel types for Vue Router integration.
|
|
@@ -49,7 +68,10 @@ declare module "@testforgejs/vue-test-core" {
|
|
|
49
68
|
}
|
|
50
69
|
|
|
51
70
|
/**
|
|
52
|
-
*
|
|
71
|
+
* Managed Vue Router plugin module for TestForge.
|
|
72
|
+
*
|
|
73
|
+
* Provides the runtime definition for creating Vue Router instances
|
|
74
|
+
* and exposes the default configuration used by TestForge-managed presets.
|
|
53
75
|
*/
|
|
54
76
|
declare const routerPlugin: PluginModuleWithDefaults<Router, VueTestRouterOptions>;
|
|
55
77
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@testforgejs/vue-test-plugin-router",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Official TestForge plugin for Vue Router integration in component tests",
|
|
6
6
|
"homepage": "https://github.com/testforgejs/testforge#readme",
|