For Programmers: Free Programming Magazines  


Home > Archive > PerlTk > May 2005 > Error in make test (regexp.t)









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Error in make test (regexp.t)
dcortesi

2005-05-30, 8:57 pm

Attempting to install under Mac OS X 10.3 everything downloads
and compiles lovely but when the tests run, just 1 of 47 scripts
fails on just 2 of 21 tests. Specifically, in regexp.t,

ok 1 - Contents as expected
ok 2 - Correct -exact postion
ok 3 - Correct -exact length
ok 4 - Correct -regexp postion
ok 5 - Correct -regexp length
ok 6 - Correct -regexp -nocase
ok 7 - Correct -exact -nocase
ok 8 - Correct -exact high-bit posn
ok 9 - Correct -exact high-bit len
not ok 10 - Correct -regexp high-bit posn
# Failed test (regexp.t at line 47)
# got: undef
# expected: '4.5'
not ok 11 - Correct -regexp high-bit len
# Failed test (regexp.t at line 48)
# got: '0'
# expected: '3'
ok 12 - Correct -regexp qr// postion
ok 13 - Correct -regexp qr// length
# 'This'
ok 14 - Right word
# 'the'
ok 15 - Right word
# 'text'
ok 16 - Right word
# '$42'
ok 17 - Right word
# '?42'
ok 18 - Right word
ok 19 - Correct -regexp postion
ok 20 - Correct -regexp length
ok 21 - UTF-8 Skip correct
# Looks like you failed 2 tests of 21.

The code of the tests that fail is:

$rposn =3D $tw->search(-count =3D> \$rcount, -nocase =3D> -regexp =3D>
'=AC=A342','1.0');
is($rposn,'4.5',"Correct -regexp high-bit posn");
is($rcount,3,"Correct -regexp high-bit len");

What are these testing?
Why are they failing? ("undef" sounds like a bug in the test?)
Where is the "search" sub they call? I can't find it...

I've gone ahead with force install and Perl/Tk appears to be working,
but what does this point to a buried problem? Or to a test error?

Thanks for any suggestions!

thundergnat

2005-05-31, 4:01 pm

dcortesi wrote:
> Attempting to install under Mac OS X 10.3 everything downloads
> and compiles lovely but when the tests run, just 1 of 47 scripts
> fails on just 2 of 21 tests. Specifically, in regexp.t,
>


[snip bunch 'o test results]

>
> $rposn = $tw->search(-count => \$rcount, -nocase => -regexp =>
> '£42','1.0');
> is($rposn,'4.5',"Correct -regexp high-bit posn");
> is($rcount,3,"Correct -regexp high-bit len");
>
> What are these testing?
> Why are they failing? ("undef" sounds like a bug in the test?)
> Where is the "search" sub they call? I can't find it...
>
> I've gone ahead with force install and Perl/Tk appears to be working,
> but what does this point to a buried problem? Or to a test error?
>
> Thanks for any suggestions!
>


The Perl/Tk test suite does a lot of operations with Unicode
characters. If the default Tk font on your system does not
have the particular character(s) used in the test implemented,
the test will fail. Don't worry too much about it. It is very
rare in my experience, that any Perl/Tk-804.xxx bundle will
pass every test unless you set up your system very carefully.

BTW, Hi D.
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com