@vitest/browser 4.1.4 → 5.0.0-beta.1
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/context.d.ts +18 -0
- package/dist/client/.vite/manifest.json +15 -6
- package/dist/client/__vitest__/assets/index-BmuVn2L3.js +136 -0
- package/dist/client/__vitest__/assets/index-CxYquQyv.css +1 -0
- package/dist/client/__vitest__/index.html +2 -2
- package/dist/client/__vitest_browser__/{orchestrator-DM4mHHP0.js → orchestrator-pTEf6o0n.js} +25 -29
- package/dist/client/__vitest_browser__/rrweb-snapshot-xhvrgOHx.js +5476 -0
- package/dist/client/__vitest_browser__/{tester-DvOWMUmv.js → tester-CIKiUsoz.js} +164 -14
- package/dist/client/__vitest_browser__/{utils-DmkAiRYk.js → utils-BYUpz6v6.js} +132 -597
- package/dist/client/orchestrator.html +2 -2
- package/dist/client/tester/tester.html +2 -2
- package/dist/client/tester/trace.d.ts +53 -0
- package/dist/client.js +1 -0
- package/dist/context.js +148 -7
- package/dist/expect-element.js +30 -30
- package/dist/index-BlWsE3ij.js +5 -0
- package/dist/index.js +22 -1
- package/dist/locators.js +1 -1
- package/dist/state.js +1 -0
- package/dist/vendor-types.d.ts +131 -0
- package/dist/vendor-types.ts +1 -0
- package/package.json +11 -6
- package/dist/client/__vitest__/assets/index-Da0hb3oU.css +0 -1
- package/dist/client/__vitest__/assets/index-DflzHTY2.js +0 -94
- package/dist/index-D8jtZoIM.js +0 -5
package/context.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import { SerializedConfig } from 'vitest'
|
|
|
2
2
|
import { StringifyOptions, CDPSession, BrowserCommands } from 'vitest/internal/browser'
|
|
3
3
|
import { ARIARole } from './aria-role.js'
|
|
4
4
|
import {} from './matchers.js'
|
|
5
|
+
import { __ivyaAriaTypes } from '@vitest/browser/internal/vendor-types'
|
|
5
6
|
|
|
6
7
|
export type BufferEncoding =
|
|
7
8
|
| 'ascii'
|
|
@@ -934,6 +935,23 @@ export const utils: {
|
|
|
934
935
|
* Creates "Cannot find element" error. Useful for custom locators.
|
|
935
936
|
*/
|
|
936
937
|
getElementError(selector: string, container?: Element): Error
|
|
938
|
+
|
|
939
|
+
/**
|
|
940
|
+
* Utilities for generating and working with ARIA trees and templates.
|
|
941
|
+
* @experimental
|
|
942
|
+
*/
|
|
943
|
+
aria: {
|
|
944
|
+
/** Captures the ARIA tree for a DOM subtree. */
|
|
945
|
+
generateAriaTree: typeof __ivyaAriaTypes.generateAriaTree
|
|
946
|
+
/** Renders a captured ARIA tree to the textual snapshot format. */
|
|
947
|
+
renderAriaTree: typeof __ivyaAriaTypes.renderAriaTree
|
|
948
|
+
/** Renders an ARIA template back to text. */
|
|
949
|
+
renderAriaTemplate: typeof __ivyaAriaTypes.renderAriaTemplate
|
|
950
|
+
/** Parses textual ARIA snapshot syntax into a template tree. */
|
|
951
|
+
parseAriaTemplate: typeof __ivyaAriaTypes.parseAriaTemplate
|
|
952
|
+
/** Matches a captured ARIA tree against a parsed template. */
|
|
953
|
+
matchAriaTree: typeof __ivyaAriaTypes.matchAriaTree
|
|
954
|
+
}
|
|
937
955
|
}
|
|
938
956
|
|
|
939
957
|
export const locators: BrowserLocators
|
|
@@ -1,24 +1,33 @@
|
|
|
1
1
|
{
|
|
2
|
-
"
|
|
3
|
-
"file": "__vitest_browser__/
|
|
2
|
+
"../../../../node_modules/.pnpm/rrweb-snapshot@2.0.0-alpha.20_patch_hash=d11ec9bd9b66247ba493ab5fd117fbf0b4cb6e5d0a6a7c600d1d844bfa3d3044/node_modules/rrweb-snapshot/dist/rrweb-snapshot.js": {
|
|
3
|
+
"file": "__vitest_browser__/rrweb-snapshot-xhvrgOHx.js",
|
|
4
|
+
"name": "rrweb-snapshot",
|
|
5
|
+
"src": "../../../../node_modules/.pnpm/rrweb-snapshot@2.0.0-alpha.20_patch_hash=d11ec9bd9b66247ba493ab5fd117fbf0b4cb6e5d0a6a7c600d1d844bfa3d3044/node_modules/rrweb-snapshot/dist/rrweb-snapshot.js",
|
|
6
|
+
"isDynamicEntry": true
|
|
7
|
+
},
|
|
8
|
+
"_utils-BYUpz6v6.js": {
|
|
9
|
+
"file": "__vitest_browser__/utils-BYUpz6v6.js",
|
|
4
10
|
"name": "utils"
|
|
5
11
|
},
|
|
6
12
|
"orchestrator.html": {
|
|
7
|
-
"file": "__vitest_browser__/orchestrator-
|
|
13
|
+
"file": "__vitest_browser__/orchestrator-pTEf6o0n.js",
|
|
8
14
|
"name": "orchestrator",
|
|
9
15
|
"src": "orchestrator.html",
|
|
10
16
|
"isEntry": true,
|
|
11
17
|
"imports": [
|
|
12
|
-
"_utils-
|
|
18
|
+
"_utils-BYUpz6v6.js"
|
|
13
19
|
]
|
|
14
20
|
},
|
|
15
21
|
"tester/tester.html": {
|
|
16
|
-
"file": "__vitest_browser__/tester-
|
|
22
|
+
"file": "__vitest_browser__/tester-CIKiUsoz.js",
|
|
17
23
|
"name": "tester",
|
|
18
24
|
"src": "tester/tester.html",
|
|
19
25
|
"isEntry": true,
|
|
20
26
|
"imports": [
|
|
21
|
-
"_utils-
|
|
27
|
+
"_utils-BYUpz6v6.js"
|
|
28
|
+
],
|
|
29
|
+
"dynamicImports": [
|
|
30
|
+
"../../../../node_modules/.pnpm/rrweb-snapshot@2.0.0-alpha.20_patch_hash=d11ec9bd9b66247ba493ab5fd117fbf0b4cb6e5d0a6a7c600d1d844bfa3d3044/node_modules/rrweb-snapshot/dist/rrweb-snapshot.js"
|
|
22
31
|
]
|
|
23
32
|
}
|
|
24
33
|
}
|