Skip Menu |

This queue is for tickets about the Graph-Writer-GraphViz CPAN distribution.

Report information
The Basics
Id: 41776
Status: open
Priority: 0/
Queue: Graph-Writer-GraphViz

People
Owner: Nobody in particular
Requestors: chad.a.davis [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: Outdated tests?
Date: Wed, 17 Dec 2008 09:24:01 +0100
To: bug-Graph-Writer-GraphViz [...] rt.cpan.org
From: "Chad Davis" <chad.a.davis [...] gmail.com>
Hello, I'm install Graph::Writer::GraphViz into a private module directory (my $HOME) and two tests are failing. Your module, however, seems to be working fine. I suspect the tests simply need to be updated? Environment: This is perl, v5.10.0 built for i486-linux-gnu-thread-multi Graph-Writer-GraphViz-0.10 Ubuntu 8.10 i686 With these distribution packages installed: graphviz-2.18-1ubuntu2 libgraphviz-perl-2.03-2 libgv-perl-2.18-1ubuntu2 Installing via cpan to $HOME The errors: # Failed test at t/1.simple.t line 23. # Failed test at t/2.ioall.t line 31. When I look at 1.simple.t it expects a graph like this: digraph test { graph [ratio=fill]; node [label="\N", color=black]; edge [color=black]; graph [bb="0,0,290,52"]; Bob [label=Bob, pos="27,26", width="0.75", height="0.50"]; Dr [label=Dr, pos="99,26", width="0.75", height="0.50"]; Alice [label=Alice, pos="174,26", width="0.83", height="0.50"]; Crude [label=Crude, pos="256,26", width="0.94", height="0.50"]; } But when I save the output in t/graph.simple.dot it contains: digraph test { graph [ratio=fill]; node [label="\N", color=black]; edge [color=black]; graph [bb="0,0,296,36"]; Bob [label=Bob, pos="28,18", width="0.78", height="0.50"]; Dr [label=Dr, pos="101,18", width="0.75", height="0.50"]; Alice [label=Alice, pos="177,18", width="0.86", height="0.50"]; Crude [label=Crude, pos="261,18", width="0.97", height="0.50"]; } These are slightly different. I suspect that is the reason the test fails. Possible due to underlying changes in graphviz itself maybe. The error from 2.ioall.t seems to be the result of the same problem. Hope that heps, Chad
RT-Send-CC: xoswald [...] debian.org:
On Mi. 17. Dez. 2008, 03:24:18, chad.a.davis@gmail.com wrote: [...] Show quoted text
> $HOME) and two tests are failing. Your module, however, seems to be
working Show quoted text
> fine. I suspect the tests simply need to be updated?
[...] I used this version, so I guess it is OK too. Show quoted text
> The errors: > # Failed test at t/1.simple.t line 23. > # Failed test at t/2.ioall.t line 31.
The attached patch fixes this. [...] Show quoted text
> These are slightly different. I suspect that is the reason the test fails.
yes [...] Regards Christian Kuelker
diff -ruN Graph-Writer-GraphViz-0.10/t/1.simple.t fixed/Graph-Writer-GraphViz-0.10/t/1.simple.t --- Graph-Writer-GraphViz-0.10/t/1.simple.t 2005-02-02 13:59:33.000000000 +0000 +++ fixed/Graph-Writer-GraphViz-0.10/t/1.simple.t 2009-07-11 15:27:38.000000000 +0000 @@ -18,8 +18,8 @@ my $g1 = <DATA>; my $g2 = io('t/graph.simple.dot')->slurp; # Ignore font-sizes, it's system-dependant -$g1 =~ s/\d/0/g; -$g2 =~ s/\d/0/g; +$g1 =~ s/\d+/0/g; +$g2 =~ s/\d+/0/g; ok($g1 eq $g2); unlink('t/graph.simple.dot'); diff -ruN Graph-Writer-GraphViz-0.10/t/2.ioall.t fixed/Graph-Writer-GraphViz-0.10/t/2.ioall.t --- Graph-Writer-GraphViz-0.10/t/2.ioall.t 2005-02-02 13:59:31.000000000 +0000 +++ fixed/Graph-Writer-GraphViz-0.10/t/2.ioall.t 2009-07-11 15:14:26.000000000 +0000 @@ -26,8 +26,8 @@ ok(-f 't/graph.ioall.dot'); # Ignore font-sizes, it's system-dependant -$g1 =~ s/\d/0/g; -$g2 =~ s/\d/0/g; +$g1 =~ s/\d+/0/g; +$g2 =~ s/\d+/0/g; ok($g1 eq $g2); $io->unlink;