Perl / perl5

🐪 The Perl programming language
https://dev.perl.org/perl5/
Other
1.97k stars 560 forks source link

Fail in dist/IO/t/cachepropagate-unix.t with perl-5.17.10 #12915

Closed p5pRT closed 11 years ago

p5pRT commented 11 years ago

Migrated from rt.perl.org#117621 (status was 'resolved')

Searchable as RT117621$

p5pRT commented 11 years ago

From @fperrad

Created by @fperrad

a test fails in dist/IO/t/cachepropagate-unix.t with perl-5.17.10 (built by perlbrew)

$ ./perl dist/IO/t/cachepropagate-unix.t 1..15 ok 1 - stream socket created ok 2 - protocol defined ok 3 - domain defined ok 4 - type defined ok 5 - spawned a child ok 6 - domain match ok 7 - protocol match ok 8 - type match ok 9 - datagram socket created ok 10 - protocol defined ok 11 - domain defined ok 12 - type defined ok 13 - domain match not ok 14 - protocol match # Failed test 'protocol match' # at dist/IO/t/cachepropagate-unix.t line 85. # got​: undef # expected​: '0' ok 15 - type match # Looks like you failed 1 test of 15.

I think that the problem comes from the specific kernel of my box (http​://www.powerdeveloper.org/platforms/efikamx/linux).

The attached patch fixes the test.

François

Perl Info ``` Flags: category=core severity=medium Site configuration information for perl 5.17.10: Configured by fperrad at Sun Apr 14 21:14:51 CEST 2013. Summary of my perl5 (revision 5 version 17 subversion 10) configuration: Platform: osname=linux, osvers=2.6.31.14.27-efikamx, archname=armv7l-linux uname='linux efikamx 2.6.31.14.27-efikamx #2 tue jul 31 17:16:25 edt 2012 armv7l gnulinux ' config_args='-de -Dprefix=/home/fperrad/perl5/perlbrew/perls/perl-5.17.10 -Dusedevel -Aeval:scriptdir=/home/fperrad/perl5/perlbrew/perls/perl-5.17.10/bin' hint=recommended, useposix=true, d_sigaction=define useithreads=undef, usemultiplicity=undef useperlio=define, d_sfio=undef, uselargefiles=define, usesocks=undef use64bitint=undef, use64bitall=undef, uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='cc', ccflags ='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64', optimize='-O2', cppflags='-fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include' ccversion='', gccversion='4.6.3', gccosandvers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=8 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='cc', ldflags =' -fstack-protector -L/usr/local/lib' libpth=/usr/local/lib /lib/arm-linux-gnueabihf /lib /usr/lib/arm-linux-gnueabihf /usr/lib libs=-lnsl -ldl -lm -lcrypt -lutil -lc perllibs=-lnsl -ldl -lm -lcrypt -lutil -lc libc=, so=so, useshrplib=false, libperl=libperl.a gnulibc_version='2.13' Dynamic Linking: dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E' cccdlflags='-fPIC', lddlflags='-shared -O2 -L/usr/local/lib -fstack-protector' Locally applied patches: @INC for perl 5.17.10: /home/fperrad/perl5/perlbrew/perls/perl-5.17.10/lib/site_perl/5.17.10/armv7l-linux /home/fperrad/perl5/perlbrew/perls/perl-5.17.10/lib/site_perl/5.17.10 /home/fperrad/perl5/perlbrew/perls/perl-5.17.10/lib/5.17.10/armv7l-linux /home/fperrad/perl5/perlbrew/perls/perl-5.17.10/lib/5.17.10 . Environment for perl 5.17.10: HOME=/home/fperrad LANG=en_US.UTF-8 LANGUAGE (unset) LD_LIBRARY_PATH (unset) LOGDIR (unset) PATH=/home/fperrad/perl5/perlbrew/bin:/home/fperrad/perl5/perlbrew/perls/perl-5.17.10/bin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games PERLBREW_BASHRC_VERSION=0.62 PERLBREW_HOME=/home/fperrad/.perlbrew PERLBREW_MANPATH=/home/fperrad/perl5/perlbrew/perls/perl-5.17.10/man PERLBREW_PATH=/home/fperrad/perl5/perlbrew/bin:/home/fperrad/perl5/perlbrew/perls/perl-5.17.10/bin PERLBREW_PERL=perl-5.17.10 PERLBREW_ROOT=/home/fperrad/perl5/perlbrew PERLBREW_VERSION=0.62 PERL_BADLANG (unset) SHELL=/bin/bash ```
p5pRT commented 11 years ago

From @fperrad

0001-fix-dist-IO-t-cachepropagate-unix.t.patch ```diff From: Francois Perrad Date: Mon, 15 Apr 2013 13:37:35 +0200 Subject: [PATCH] fix dist/IO/t/cachepropagate-unix.t same fix as in the last commit in cachepropagate-udp.t Signed-off-by: Francois Perrad --- dist/IO/t/cachepropagate-unix.t | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/dist/IO/t/cachepropagate-unix.t b/dist/IO/t/cachepropagate-unix.t index 30c8473..228083a 100644 --- a/dist/IO/t/cachepropagate-unix.t +++ b/dist/IO/t/cachepropagate-unix.t @@ -50,10 +50,14 @@ is($new->sockdomain(), $d, 'domain match'); SKIP: { skip "no Socket::SO_PROTOCOL", 1 if !defined(eval { Socket::SO_PROTOCOL }); + skip "SO_PROTOCOL defined but not implemented", 1 + if !defined $new->sockopt(Socket::SO_PROTOCOL); is($new->protocol(), $p, 'protocol match'); } SKIP: { skip "no Socket::SO_TYPE", 1 if !defined(eval { Socket::SO_TYPE }); + skip "SO_TYPE defined but not implemented", 1 + if !defined $new->sockopt(Socket::SO_TYPE); is($new->socktype(), $s, 'type match'); } @@ -82,10 +86,14 @@ is($new->sockdomain(), $d, 'domain match'); SKIP: { skip "no Socket::SO_PROTOCOL", 1 if !defined(eval { Socket::SO_PROTOCOL }); + skip "SO_PROTOCOL defined but not implemented", 1 + if !defined $new->sockopt(Socket::SO_PROTOCOL); is($new->protocol(), $p, 'protocol match'); } SKIP: { skip "no Socket::SO_TYPE", 1 if !defined(eval { Socket::SO_TYPE }); + skip "SO_TYPE defined but not implemented", 1 + if !defined $new->sockopt(Socket::SO_TYPE); is($new->socktype(), $s, 'type match'); } } -- 1.7.9.5 ```
p5pRT commented 11 years ago

From @tonycoz

On Mon Apr 15 05​:02​:44 2013\, fperrad wrote​:

a test fails in dist/IO/t/cachepropagate-unix.t with perl-5.17.10 (built by perlbrew)

$ ./perl dist/IO/t/cachepropagate-unix.t 1..15 ok 1 - stream socket created ok 2 - protocol defined ok 3 - domain defined ok 4 - type defined ok 5 - spawned a child ok 6 - domain match ok 7 - protocol match ok 8 - type match ok 9 - datagram socket created ok 10 - protocol defined ok 11 - domain defined ok 12 - type defined ok 13 - domain match not ok 14 - protocol match # Failed test 'protocol match' # at dist/IO/t/cachepropagate-unix.t line 85. # got​: undef # expected​: '0' ok 15 - type match # Looks like you failed 1 test of 15.

I think that the problem comes from the specific kernel of my box (http​://www.powerdeveloper.org/platforms/efikamx/linux).

The attached patch fixes the test.

Thanks\, applied as 92fd341d686f8070e93bb8b19656c69b82966d3d.

Tony

p5pRT commented 11 years ago

The RT System itself - Status changed from 'new' to 'open'

p5pRT commented 11 years ago

@tonycoz - Status changed from 'open' to 'resolved'