Skip Menu |

This queue is for tickets about the HTML-FormFu CPAN distribution.

Report information
The Basics
Id: 45433
Status: resolved
Priority: 0/
Queue: HTML-FormFu

People
Owner: Nobody in particular
Requestors: kmx [...] volny.cz
Cc:
AdminCc:

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



Subject: t/deflators/pathclassfile.t fails on Win32/strawberry
Date: Sun, 26 Apr 2009 11:04:46 +0200
To: bug-HTML-FormFu [...] rt.cpan.org
From: kmx <kmx [...] volny.cz>
Hi, when installing FormFu 0.04001 on Win32 Strawberry Perl (5.8.8) t/deflators/pathclassfile.t fails with the following error: t/deflators/compoundsplit_split.t ........................ ok t/deflators/formatnumber.t ............................... ok t/deflators/pathclassfile.t .............................. 1/4 # Failed test at t/deflators/pathclassfile.t line 30. # '<div class="text"> # <input name="test1" type="text" value="t\deflators\pathclassfile.t" /> # </div>' # doesn't match '(?-xism:value="t\deflators\pathclassfile.t")' # Failed test at t/deflators/pathclassfile.t line 32. # '<div class="text"> # <input name="test2" type="text" value="deflators\pathclassfile.t" /> # </div>' # doesn't match '(?-xism:value="deflators\pathclassfile.t")' Unrecognized escape \H passed through in regex; marked by <-- HERE in m/value="D:\Devel\Perl\Catalyst.install\XXX\H <-- HERE TML-FormFu-0.04001.orig\t\deflators\pathclassfile.t"/ at t/deflators/pathclassfile.t line 34. # Failed test at t/deflators/pathclassfile.t line 34. # '<div class="text"> # <input name="test3" type="text" value="D:\Devel\Perl\Catalyst.install\XXX\HTML-FormFu-0.04001.orig\t\deflators\pathclassfile.t" /> # </div>' # doesn't match '(?-xism:value="D:\Devel\Perl\Catalyst.install\XXX\HTML-FormFu-0.04001.orig\t\deflators\pathclassfile.t")' # Looks like you failed 3 tests of 4. t/deflators/pathclassfile.t .............................. Dubious, test returned 3 (wstat 768, 0x300) Failed 3/4 subtests t/deprecated/element_defaults.t .......................... element_defaults() method deprecated and is provided for compatability only: use default_args()->{elements} instead as this will be removed element_defaults() method deprecated and is provided for compatability only: use default_args()->{elements} instead as this will be removed t/deprecated/element_defaults.t .......................... 1/6 element_defaults() method deprecated and is provided for compatability only: use default_args()->{elements} instead as this will be removed t/deprecated/element_defaults.t .......................... ok t/element_setup.t ........................................ ok t/elements/blank.t ....................................... ok It seems that pathclassfile.t is not happy with backslashes in pathnames on Win32. The following patch for t/deflators/pathclassfile.t solves the problem: -my $value = "\Q".$file->relative."\E"; -like($form->get_field('test1'), qr{value="$value"}); -$value = "\Q".$file->relative('t')."\E"; -like($form->get_field('test2'), qr{value="$value"}); -$value = "\Q".$file->absolute."\E"; -like($form->get_field('test3'), qr{value="$value"}); -$value = "\Q".$file->basename."\E"; -like($form->get_field('test4'), qr{value="$value"}); +my $value = $file->relative; +like($form->get_field('test1'), qr{value="\Q$value\E"}); +$value = $file->relative('t'); +like($form->get_field('test2'), qr{value="\Q$value\E"}); +$value = $file->absolute; +like($form->get_field('test3'), qr{value="\Q$value\E"}); +$value = $file->basename; +like($form->get_field('test4'), qr{value="\Q$value\E"}); -- kmx
This should be fixed by v0.04002 now on cpan