Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

small problem with diag in Test module #5307

Closed
p6rt opened this issue May 8, 2016 · 4 comments
Closed

small problem with diag in Test module #5307

p6rt opened this issue May 8, 2016 · 4 comments

Comments

@p6rt
Copy link

p6rt commented May 8, 2016

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

Searchable as RT128098$

@p6rt
Copy link
Author

p6rt commented May 8, 2016

From @MARTIMM

Hi,

Since I found the Test module in the rakudo project I file the bug here.

When the diag() sub is called before any tests are done the message will
not be printed when prove is run without the verbose option.

Small test file;

use v6.c;
use Test;

diag 'test message';
ok True, 'ok';

done-testing;

Test command with verbose on

prove -e perl6 -v Tests.t
Tests.t ..
# test message
ok 1 - ok
1..1
ok
All tests successful.
Files=1, Tests=1, 0 wallclock secs ( 0.02 usr 0.00 sys + 0.24 cusr
0.02 csys = 0.28 CPU)Result​: PASS

Test command with verbose off

prove -e perl6 Tests.t
Tests.t .. ok
All tests successful.
Files=1, Tests=1, 0 wallclock secs ( 0.02 usr 0.00 sys + 0.27 cusr
0.02 csys = 0.31 CPU)
Result​: PASS

Adding a test before the diag line like another "ok True, 'ok';" and
test again with verbose off

prove -e perl6 Tests.t
Tests.t .. 1/? # test message
Tests.t .. ok
All tests successful.
Files=1, Tests=2, 1 wallclock secs ( 0.02 usr 0.00 sys + 0.29 cusr
0.03 csys = 0.34 CPU)
Result​: PASS

This is Rakudo version 2016.04-7-g331e79f built on MoarVM version 2016.04
implementing Perl 6.c.

Greetings,
Marcel

@p6rt
Copy link
Author

p6rt commented Jul 17, 2016

From @zoffixznet

Thanks for reporting.

Fixed in rakudo/rakudo@68b66c2f71

Tests added into Rakudo's test suite in the same commit.

@p6rt
Copy link
Author

p6rt commented Jul 17, 2016

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

@p6rt
Copy link
Author

p6rt commented Jul 17, 2016

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

@p6rt p6rt closed this as completed Jul 17, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant