(node)
| 1707 | function compactQueryNodes(snapshot) { |
| 1708 | const nodes = []; |
| 1709 | const visit = (node) => { |
| 1710 | if (!node || typeof node !== "object") { |
| 1711 | return; |
| 1712 | } |
| 1713 | if ( |
| 1714 | "role" in node || |
| 1715 | "id" in node || |
| 1716 | "label" in node || |
| 1717 | "value" in node || |
| 1718 | "frame" in node |
| 1719 | ) { |
| 1720 | nodes.push(node); |
| 1721 | } |
| 1722 | for (const child of Array.isArray(node.children) ? node.children : []) { |
| 1723 | visit(child); |
| 1724 | } |
| 1725 | }; |
| 1726 | for (const match of Array.isArray(snapshot?.matches) |
| 1727 | ? snapshot.matches |
| 1728 | : []) { |
no outgoing calls
no test coverage detected