@siteimprove/alfa-cypress 0.72.2 → 0.73.2

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/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # @siteimprove/alfa-cypress
2
2
 
3
+ ## 0.73.2
4
+
5
+ ### Patch Changes
6
+
7
+ - **Changed:** Update Alfa and yarn ([#87](https://github.com/Siteimprove/alfa-integrations/pull/87))
8
+
9
+ ## 0.73.1
10
+
11
+ ## 0.73.0
12
+
13
+ ### Minor Changes
14
+
15
+ - **Changed:** Reverting publication process. Use this version. ([`0d018f8`](https://github.com/Siteimprove/alfa-integrations/commit/0d018f84d1fe0f714f397de88c4bd3e6434cba57))
16
+
3
17
  ## 0.72.2
4
18
 
5
19
  ## 0.72.1
package/dist/cypress.js CHANGED
@@ -42,7 +42,14 @@ export var Cypress;
42
42
  value = value.get(0);
43
43
  }
44
44
  const nodeJSON = await dom.Native.fromNode(value);
45
- const deviceJSON = device.Native.fromWindow(window);
45
+ // This escapes shadow DOM, but not iframes!
46
+ const root = value.getRootNode({ composed: true });
47
+ // If the root is a document, we can get its window for building the
48
+ // device. Otherwise, we hope that the global window object is decent.
49
+ const view = (root.nodeType === root.DOCUMENT_NODE
50
+ ? root.defaultView
51
+ : undefined) ?? window;
52
+ const deviceJSON = device.Native.fromWindow(view);
46
53
  const pageDevice = Device.from(deviceJSON);
47
54
  return Page.of(Request.empty(), Response.empty(), nodeJSON.type === "document"
48
55
  ? Document.from(nodeJSON, pageDevice)
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "http://json.schemastore.org/package",
3
3
  "name": "@siteimprove/alfa-cypress",
4
4
  "homepage": "https://alfa.siteimprove.com",
5
- "version": "0.72.2",
5
+ "version": "0.73.2",
6
6
  "license": "MIT",
7
7
  "description": "Integrations and utilities for the Cypress testing framework",
8
8
  "repository": {
@@ -21,27 +21,31 @@
21
21
  "dist/**/*.js",
22
22
  "dist/**/*.d.ts"
23
23
  ],
24
+ "scripts": {
25
+ "test": "cypress run"
26
+ },
24
27
  "dependencies": {
25
- "@siteimprove/alfa-act": "^0.92.0",
26
- "@siteimprove/alfa-assert": "^0.72.2",
27
- "@siteimprove/alfa-device": "^0.92.0",
28
- "@siteimprove/alfa-dom": "^0.92.0",
29
- "@siteimprove/alfa-formatter": "^0.72.2",
30
- "@siteimprove/alfa-formatter-earl": "^0.72.2",
31
- "@siteimprove/alfa-hash": "^0.92.0",
32
- "@siteimprove/alfa-http": "^0.92.0",
33
- "@siteimprove/alfa-mapper": "^0.92.0",
34
- "@siteimprove/alfa-web": "^0.92.0",
35
- "cypress": "^13.3.1"
28
+ "@siteimprove/alfa-act": "^0.93.0",
29
+ "@siteimprove/alfa-assert": "^0.73.2",
30
+ "@siteimprove/alfa-device": "^0.93.0",
31
+ "@siteimprove/alfa-dom": "^0.93.0",
32
+ "@siteimprove/alfa-formatter": "^0.73.2",
33
+ "@siteimprove/alfa-formatter-earl": "^0.73.2",
34
+ "@siteimprove/alfa-hash": "^0.93.0",
35
+ "@siteimprove/alfa-http": "^0.93.0",
36
+ "@siteimprove/alfa-mapper": "^0.93.0",
37
+ "@siteimprove/alfa-web": "^0.93.0",
38
+ "cypress": "^13.14.2"
36
39
  },
37
40
  "peerDependencies": {
38
- "@siteimprove/alfa-act": "^0.92.0",
39
- "@siteimprove/alfa-device": "^0.92.0",
40
- "@siteimprove/alfa-dom": "^0.92.0",
41
- "@siteimprove/alfa-hash": "^0.92.0",
42
- "@siteimprove/alfa-http": "^0.92.0",
43
- "@siteimprove/alfa-mapper": "^0.92.0",
44
- "@siteimprove/alfa-web": "^0.92.0"
41
+ "@siteimprove/alfa-act": "^0.93.0",
42
+ "@siteimprove/alfa-device": "^0.93.0",
43
+ "@siteimprove/alfa-dom": "^0.93.0",
44
+ "@siteimprove/alfa-hash": "^0.93.0",
45
+ "@siteimprove/alfa-http": "^0.93.0",
46
+ "@siteimprove/alfa-mapper": "^0.93.0",
47
+ "@siteimprove/alfa-web": "^0.93.0",
48
+ "cypress": "^13.14.2"
45
49
  },
46
50
  "publishConfig": {
47
51
  "access": "public",