>>>>> "Paul" == Paul Johnson <[EMAIL PROTECTED]> writes:
Paul> Claude said:
>> Hello,
>>
>> I tried to create a test suite file containing the following code:
>>
>> ------ clip -------
>> #! /usr/local/bin/perl
>>
>> use strict;
>> use Test::Harness qw( &runtests $verbose );
>> $verbose=1;
>> my @AoC = ( "t/00.pl" );
>> my $len = @AoC;
>> print "1..$len\n";
Paul> This line should be in the test scripts rather than the harness.
>> runtests( @AoC );
>> ------ clip -------
>>
>> The file t/00.pl contains the following lines:
>>
>> ------ clip -------
>> #! /usr/local/bin/perl
>>
>> print "ok\n";
Paul> Here you want something like:
Paul> use Test::More tests => 1;
Why would I need this separated module? I understood I can live
without it. Am I wrong?
Paul> my $x = "qaz";
Paul> is $x, "qaz", "qaz matches";
>> What am I doing wrong?
Paul> There is usually no need for your first file.
Where would I run the runtest() from then?
Paul> The standard way to set things up is to put the tests in the t
Paul> directory,
I did that. but I don't want to run all of them. I found the runtest()
call passed a array of test kind of handy for me.
Paul> let MakeMaker do its magic, and then run make test.
Paul> Unless you have specific requirements which preclude this, I
Paul> would suggest that approach.
Magic? Sorry, I could not understand that. I am still stuck with the
way to handle Test::Harness.
Is there any newsgroup more appropriate that this one?
Tx for your answer and time.
--
Claude
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>