develooper Front page | perl.cpan.workers | Postings from June 2014

Re: RFC Consensus on Network testing ENV?

Thread Previous | Thread Next
From:
Jens Rehsack
Date:
June 11, 2014 18:37
Subject:
Re: RFC Consensus on Network testing ENV?
Message ID:
24B533CA-BF71-4D37-B66B-3726F738CFAA@gmail.com

Am 11.06.2014 um 20:24 schrieb Kent Fredric <kentfredric@gmail.com>:

> 
> On 12 June 2014 05:58, Jens Rehsack <rehsack@gmail.com> wrote:
> You never know whether a test fails because of failure or insufficient
> capabilities. So a restricting envvar isn't worse at all.
> 
> I think he was more saying that he'd prefer: 
> 
>     set NO_NETWORK_TESTING=1
> 
> over 
> 
>     set NETWORK_TESTING=1

I would prefer LOCALTESTS_ONLY=1 over NO_NETWORK_TESTING=1

> Where network testing should run by default and users on boxes where it *couldnt* work ( for whatever reason ) could disable it.
> 
> That would be more helpful on an imaginary example environment that was sandboxed where calling network functions during 'make test' triggers a SIGKILL or something.
> 
> And then with that proviso agreed upon, have a module that ascertains ( using basic testing within the test itself ) if network behaviour is conducive to making the test pass, and if so, permit the test to run ( guarding the test against actual network problems instead of relying on an ENV guard , and using the ENV guard only for users who have continued issues with the heuristic failing to fail properly )
> 
> 1. begin test
> 2. load test networking module module
> 3. is NO_NETWORK_TESTING? SKIP!
> 4. can access specified resources?  yes -> run tests
>                                                       no   -> SKIP!

In that case I suggest to FAIL instead of skip. Maybe is that part of the error.

Cheers
-- 
Jens Rehsack
rehsack@gmail.com






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