develooper Front page | perl.module-authors | Postings from October 2005

Re: Tests needing user parameters

Thread Previous | Thread Next
From:
Ken Williams
Date:
October 20, 2005 14:46
Subject:
Re: Tests needing user parameters
Message ID:
72adca226d2f7f8610058432d43e3bc3@mathforum.org

On Oct 20, 2005, at 6:14 AM, Jess Robinson wrote:

>
>
> On Thu, 20 Oct 2005, A. Pagaltzis wrote:
>
>> * David Landgren <david@landgren.net> [2005-10-20 10:30]:
>>> Jess Robinson wrote:
>>>> Right, I'd seen a few modules do this, but.. Is there a
>>>> *standard* way of doing it? Those Makefile.PLs tend to look
>>>> cluttered and confusing IMO.. a nice:
>>>>
>>>> use Test::Auth;
>>>> get_user_fields("user", "password");
>>>>
>>>> would be preferable.. (hmmm, could write something that does
>>>> that, using IO::Prompt.. anyone interested?)
>>>
>>> If there's a standard way of doing it, it would be really nice
>>> that it understood when it was being run in a smoke
>>> environment, and asked no questions and used built-in defaults.
>>
>> That's exactly what EU::MM's prompt() function and
>> Module::Build's prompt() method do/are for.
>>
>
> Thanks, that sounds like what I was looking for!

Oh yeah, I meant to mention prompt() and y_n() (which is M::B-only) but 
I forgot.

>
> (hmm, assuming I can pass the results on to make test.. I'll have a 
> look)

That's what notes() is for.  If you don't want to use Module::Build, 
you'll just have to cobble something together yourself, which is what I 
was talking about when I said you'd have to write it to a file 
someplace.

  -Ken


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About