Skip Menu |

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

Report information
The Basics
Id: 5065
Status: resolved
Priority: 0/
Queue: Graph-ReadWrite

People
Owner: Nobody in particular
Requestors: eric.azais [...] free.fr
Cc:
AdminCc:

Bug Information
Severity: Unimportant
Broken in: 1.07
Fixed in: 2.02



Subject: Graph-ReadWrite-1.07 test failure on Win32
I am installing Graph-Reader-1.07 in a 5.8.2.808-Win32 installation of ActivePerl. The distibution test fails on the second test of the reader module and all the tests of the simple module: C:\temp\.cpan\build\Graph-ReadWrite-1.07>nmake test Microsoft (R) Program Maintenance Utility Version 1.50 Copyright (c) Microsoft Corp 1988-94. All rights reserved. C:\WINDOWS\Perl\bin\perl.exe "-MExtUtils::Command::MM" "-e" "test_harnes s(0, 'blib\lib', 'blib\arch')" t\base.t t\reader.t t\simple.t t\base......ok t\reader....Using a hash as a reference is deprecated at Graph_Reader_Dot.yp lin e 75. Using an array as a reference is deprecated at Graph_Reader_Dot.yp line 145. Use of uninitialized value in substitution (s///) at Graph_Reader_Dot.yp line 31 2. Use of uninitialized value in string eq at Graph_Reader_Dot.yp line 313. t\reader....FAILED test 2 Failed 1/3 tests, 66.67% okay t\simple....FAILED tests 1-5 Failed 5/5 tests, 0.00% okay Failed Test Stat Wstat Total Fail Failed List of Failed The pattern of the failing tests is the generation of a graph file followed by the binary comparison with a reference file. This works fine on Unix but not on Windows. Due to the difference of text line termination between these two OSes, the generated file (Windows format) is equivalent but not strictly equal to the reference file (Unix format). Using File::Compare::compare_text() instead of compare() yelds a test success. XML files and dot files can use Windows' line termination. I don't know if VCG, HTK and davinci, file specifications allow this termination. So I just joined a patch for XML and dot tests.
*** t\simple.t.org Sun Jan 13 14:20:43 2002 --- t\simple.t Tue Jan 27 23:26:42 2004 *************** *** 36,42 **** $writer = Graph::Writer::XML->new(); if (defined($writer) && $writer->write_graph($graph, $genfile) ! && compare($genfile, $expected) == 0) { print "ok 1\n"; } else { --- 36,42 ---- $writer = Graph::Writer::XML->new(); if (defined($writer) && $writer->write_graph($graph, $genfile) ! && File::Compare::compare_text($genfile, $expected) == 0) { print "ok 1\n"; } else { *************** *** 68,74 **** $writer = Graph::Writer::Dot->new(); if (defined($writer) && $writer->write_graph($graph, $genfile) ! && compare($genfile, $expected) == 0) { print "ok 3\n"; } else { --- 68,74 ---- $writer = Graph::Writer::Dot->new(); if (defined($writer) && $writer->write_graph($graph, $genfile) ! && File::Compare::compare_text($genfile, $expected) == 0) { print "ok 3\n"; } else {