Front page | perl.vmsperl |
Postings from May 2002
RE: VOS bleadperl test failure on 16539
Thread Next
From:
chromatic
Date:
May 12, 2002 03:11
Subject:
RE: VOS bleadperl test failure on 16539
Message ID:
20020512072814.50744.qmail@onion.perl.org
On Sat, 11 May 2002 20:09:56 -0700, Paul Green wrote:
> Sure enough, it appears that the STDERR output is written first, before the
> STDOUT output. I suspect we got the STDERR output line caught up in a buffer
> somewhere. I suspect an OS issue lurking around. But I'm too tired to pursue
> it further tonight.
If it's a test bug (and relying on one filehandle to flush before the other
wasn't my best idea), maybe autoflushing STDOUT will help. Here's a patch
against the test.
This may help VMS too.
Hacking B::ToXML and B::FromXML,
-- c
--- ext/B/t/o.t~ Sat May 11 23:13:44 2002
+++ ext/B/t/o.t Sat May 11 23:18:32 2002
@@ -30,10 +30,10 @@
my @args = ('-Ilib', '-MO=success,foo,bar', '-e', '1' );
my @lines = get_lines( @args );
-is( $lines[0], '-e syntax OK', 'O.pm should not munge perl output without -qq');
-is( $lines[1], 'Compiling!', 'Output should not be saved without -q switch' );
-is( $lines[2], '(foo) <bar>', 'O.pm should call backend compile() method' );
-is( $lines[3], '[]', 'Nothing should be in $O::BEGIN_output without -q' );
+is( $lines[0], 'Compiling!', 'Output should not be saved without -q switch' );
+is( $lines[1], '(foo) <bar>', 'O.pm should call backend compile() method' );
+is( $lines[2], '[]', 'Nothing should be in $O::BEGIN_output without -q' );
+is( $lines[3], '-e syntax OK', 'O.pm should not munge perl output without -qq');
$args[1] = '-MO=-q,success,foo,bar';
@lines = get_lines( @args );
@@ -42,7 +42,7 @@
SKIP: {
skip( '-q redirection does not work without PerlIO', 2)
unless $Config{useperlio};
- is( $lines[2], "[Compiling!", '... but should be in $O::BEGIN_output' );
+ is( $lines[1], "[Compiling!", '... but should be in $O::BEGIN_output' );
$args[1] = '-MO=-qq,success,foo,bar';
@lines = get_lines( @args );
@@ -51,7 +51,7 @@
$args[1] = '-MO=success,fail';
@lines = get_lines( @args );
-like( $lines[0], qr/fail at .eval/,
+like( $lines[1], qr/fail at .eval/,
'O.pm should die if backend compile() does not return a subref' );
sub get_lines {
@@ -65,6 +65,7 @@
__END__
package B::success;
+$| = 1;
print "Compiling!\n";
sub compile {
Thread Next