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

Re: RFC Consensus on Network testing ENV?

Thread Previous | Thread Next
From:
Kent Fredric
Date:
June 11, 2014 18:24
Subject:
Re: RFC Consensus on Network testing ENV?
Message ID:
CAATnKFA483RbPwfshdTj4oPs97a7OD4UOjND17Lyd7K9BRKM4g@mail.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

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!


-- 
Kent

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