aboutsummaryrefslogtreecommitdiff
path: root/tests/graphviz.scm
diff options
context:
space:
mode:
Diffstat (limited to 'tests/graphviz.scm')
-rw-r--r--tests/graphviz.scm15
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/graphviz.scm b/tests/graphviz.scm
index bb99edc..b61cc61 100644
--- a/tests/graphviz.scm
+++ b/tests/graphviz.scm
@@ -27,6 +27,9 @@
(define graph-node
(@@ (ccwl graphviz) graph-node))
+(define graph-port
+ (@@ (ccwl graphviz) graph-port))
+
(define html-string
(@@ (ccwl graphviz) html-string))
@@ -58,4 +61,16 @@
`((label . "foo\\lbar")))))
port))))
+(test-equal "serialize ports correctly"
+ "digraph foo {
+ foo:p1 -> bar:p2;
+}
+"
+ (call-with-output-string
+ (lambda (port)
+ (graph->dot
+ (graph 'foo
+ #:edges `((,(graph-port "foo" "p1") . ,(graph-port "bar" "p2"))))
+ port))))
+
(test-end "graphviz")