From faf6949033a021bffab3c91a04665efef4378b28 Mon Sep 17 00:00:00 2001 From: franck cuny Date: Fri, 16 Jul 2010 11:19:15 +0200 Subject: basic gexf generation --- t/03-node.t | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 t/03-node.t (limited to 't/03-node.t') diff --git a/t/03-node.t b/t/03-node.t new file mode 100644 index 0000000..ccd79fe --- /dev/null +++ b/t/03-node.t @@ -0,0 +1,19 @@ +use strict; +use warnings; +use Test::More; + +use Graph::GEXF::Node; + +ok my $node = Graph::GEXF::Node->new(id =>0), 'node created'; + +ok !$node->attribute('url', 'http://linkfluence.net'), 'can\'t add attribute, not attributes defined'; + +ok $node = Graph::GEXF::Node->new( + id => 0, + attributes => {url => {title => 'url', type => 'anyURI'}} + ), + 'node created'; + +ok $node->attribute('url', 'http://linkfluence.net'), 'add attribute url to node'; + +done_testing; -- cgit v1.2.3