]> granicus.if.org Git - graphviz/commitdiff
add a test case for #121
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Tue, 21 Jun 2022 02:49:12 +0000 (19:49 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Sun, 26 Jun 2022 21:27:34 +0000 (14:27 -0700)
tests/121.dot [new file with mode: 0644]
tests/test_regression.py

diff --git a/tests/121.dot b/tests/121.dot
new file mode 100644 (file)
index 0000000..e6efade
--- /dev/null
@@ -0,0 +1,26 @@
+digraph G
+{
+  subgraph cluster_G1
+  {
+    {
+      rank=same;
+      A -> B;
+    }
+
+    C -> A;
+  }
+
+  subgraph cluster_G2
+  {
+    {
+      rank=same;
+      D -> E;
+    }
+
+    F -> E;
+  }
+
+  B -> D [ constraint=none ];
+  B -> D [ constraint=none ];
+}
+
index 5a6c4aa7869dc317fe92dbbca887c10c8f71df37..35cdb313c2393522c91319308ee62c603fd71bd1 100644 (file)
@@ -104,6 +104,20 @@ def test_56():
   # process it with Graphviz
   dot("svg", input)
 
+@pytest.mark.xfail()
+def test_121():
+  """
+  test a graph that previously caused an assertion failure in `merge_chain`
+  https://gitlab.com/graphviz/graphviz/-/issues/121
+  """
+
+  # locate our associated test case in this directory
+  input = Path(__file__).parent / "121.dot"
+  assert input.exists(), "unexpectedly missing test case"
+
+  # process it with Graphviz
+  dot("pdf", input)
+
 def test_131():
   """
   PIC back end should produce valid output