From 2d9034c983e724c6df8e7af6f5f5cedaa6467f01 Mon Sep 17 00:00:00 2001 From: khalil <5alil.landolsi@gmail.com> Date: Sat, 5 Apr 2025 21:30:03 +0100 Subject: [PATCH] fixed unit test --- .../mermaid/src/diagrams/state/stateDiagram-v2.spec.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/packages/mermaid/src/diagrams/state/stateDiagram-v2.spec.js b/packages/mermaid/src/diagrams/state/stateDiagram-v2.spec.js index 0df17e53a..b31dfd953 100644 --- a/packages/mermaid/src/diagrams/state/stateDiagram-v2.spec.js +++ b/packages/mermaid/src/diagrams/state/stateDiagram-v2.spec.js @@ -449,6 +449,13 @@ describe('state diagram V2, ', function () { click StateA "https://example.com" "Go to Example" `; + stateDb.clear(); + + parser.yy = { + ...stateDb, + addLink: stateDb.addLink.bind(stateDb), + }; + parser.parse(diagram); const links = stateDb.getLinks();