



























@@ -395,12 +395,12 @@ describe("cdp internal", () => {
395395396396describe("formatAriaSnapshot", () => {
397397it("returns an empty array when the AX tree is empty", () => {
398-expect(formatAriaSnapshot([], 100)).toEqual([]);
398+expect(formatAriaSnapshot([], 100)).toStrictEqual([]);
399399});
400400401401it("returns an empty array when no node has an id", () => {
402402const nodes = [{ role: { value: "Role" }, name: { value: "" } }] as unknown as RawAXNode[];
403-expect(formatAriaSnapshot(nodes, 100)).toEqual([]);
403+expect(formatAriaSnapshot(nodes, 100)).toStrictEqual([]);
404404});
405405406406it("skips child references that are absent from the node map", () => {
@@ -492,7 +492,7 @@ describe("cdp internal", () => {
492492});
493493wss = server.wss;
494494const snap = await snapshotAria({ wsUrl: server.wsUrl });
495-expect(snap.nodes).toEqual([]);
495+expect(snap.nodes).toStrictEqual([]);
496496});
497497});
498498@@ -733,7 +733,7 @@ describe("cdp internal", () => {
733733});
734734wss = server.wss;
735735const snap = await snapshotDom({ wsUrl: server.wsUrl });
736-expect(snap.nodes).toEqual([]);
736+expect(snap.nodes).toStrictEqual([]);
737737});
738738739739it("returns an empty nodes array when nodes is not an array", async () => {
@@ -753,7 +753,7 @@ describe("cdp internal", () => {
753753});
754754wss = server.wss;
755755const snap = await snapshotDom({ wsUrl: server.wsUrl });
756-expect(snap.nodes).toEqual([]);
756+expect(snap.nodes).toStrictEqual([]);
757757});
758758});
759759@@ -864,7 +864,7 @@ describe("cdp internal", () => {
864864});
865865wss = server.wss;
866866const out = await querySelector({ wsUrl: server.wsUrl, selector: "button" });
867-expect(out.matches).toEqual([]);
867+expect(out.matches).toStrictEqual([]);
868868});
869869});
870870@@ -1095,7 +1095,7 @@ describe("cdp internal", () => {
10951095});
10961096wss = server.wss;
10971097const snap = await snapshotAria({ wsUrl: server.wsUrl });
1098-expect(snap.nodes).toEqual([]);
1098+expect(snap.nodes).toStrictEqual([]);
10991099});
1100110011011101it("swallows a failing Runtime.enable in evaluateJavaScript", async () => {
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。