Re: [Numpy-discussion] pytest and degrees of separation.

2017-07-11 Thread Chris Barker
On Tue, Jul 11, 2017 at 5:04 PM, Thomas Caswell  wrote:

> Going with option 2 is probably the best option so that you can use pytest
> fixtures and parameterization.
>

I agree -- those are worth a lot!

-CHB



> Might be worth looking at how Matplotlib re-arranged things on our master
> branch to maintain back-compatibility with nose-specific tools that were
> used by down-stream projects.
>
> Tom
>
> On Tue, Jul 11, 2017 at 4:22 PM Sebastian Berg 
> wrote:
>
>> On Tue, 2017-07-11 at 14:49 -0600, Charles R Harris wrote:
>> > Hi All,
>> >
>> > Just looking for opinions and feedback on the need to keep NumPy from
>> > having a hard nose/pytest dependency. The options as I see them are:
>> >
>> > pytest is never imported until the tests are run -- current practice
>> > with nose
>> > pytest is never imported unless the testfiles are imported -- what I
>> > would like
>> > pytest is imported together when numpy is -- what we need to avoid.
>> > Currently the approach has been 1), but I think 2) makes more sense
>> > and allows more flexibility.
>>
>>
>> I am not quite sure about everything here. My guess is we can do
>> whatever we want when it comes to our own tests, and I don't mind just
>> switching everything to pytest (I for one am happy as long as I can run
>> `runtests.py` ;)).
>> When it comes to the utils we provide, those should keep working
>> without nose/pytest if they worked before without it I think.
>>
>> My guess is that all your options do that, so I think we should take
>> the one that gives the nicest maintainable code :). Though can't say I
>> looked enough into it to really make a well educated decision, that
>> probably means your option 2.
>>
>> - Sebastian
>>
>>
>>
>> > Thoughts?
>> > Chuck
>> > ___
>> > NumPy-Discussion mailing list
>> > NumPy-Discussion@python.org
>> > https://mail.python.org/mailman/listinfo/numpy-discussion
>> ___
>> NumPy-Discussion mailing list
>> NumPy-Discussion@python.org
>> https://mail.python.org/mailman/listinfo/numpy-discussion
>>
>
> ___
> NumPy-Discussion mailing list
> NumPy-Discussion@python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion
>
>


-- 

Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R(206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115   (206) 526-6317   main reception

chris.bar...@noaa.gov
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] pytest and degrees of separation.

2017-07-11 Thread Thomas Caswell
Going with option 2 is probably the best option so that you can use pytest
fixtures and parameterization.

Might be worth looking at how Matplotlib re-arranged things on our master
branch to maintain back-compatibility with nose-specific tools that were
used by down-stream projects.

Tom

On Tue, Jul 11, 2017 at 4:22 PM Sebastian Berg 
wrote:

> On Tue, 2017-07-11 at 14:49 -0600, Charles R Harris wrote:
> > Hi All,
> >
> > Just looking for opinions and feedback on the need to keep NumPy from
> > having a hard nose/pytest dependency. The options as I see them are:
> >
> > pytest is never imported until the tests are run -- current practice
> > with nose
> > pytest is never imported unless the testfiles are imported -- what I
> > would like
> > pytest is imported together when numpy is -- what we need to avoid.
> > Currently the approach has been 1), but I think 2) makes more sense
> > and allows more flexibility.
>
>
> I am not quite sure about everything here. My guess is we can do
> whatever we want when it comes to our own tests, and I don't mind just
> switching everything to pytest (I for one am happy as long as I can run
> `runtests.py` ;)).
> When it comes to the utils we provide, those should keep working
> without nose/pytest if they worked before without it I think.
>
> My guess is that all your options do that, so I think we should take
> the one that gives the nicest maintainable code :). Though can't say I
> looked enough into it to really make a well educated decision, that
> probably means your option 2.
>
> - Sebastian
>
>
>
> > Thoughts?
> > Chuck
> > ___
> > NumPy-Discussion mailing list
> > NumPy-Discussion@python.org
> > https://mail.python.org/mailman/listinfo/numpy-discussion
> ___
> NumPy-Discussion mailing list
> NumPy-Discussion@python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion
>
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] pytest and degrees of separation.

2017-07-11 Thread Sebastian Berg
On Tue, 2017-07-11 at 14:49 -0600, Charles R Harris wrote:
> Hi All,
> 
> Just looking for opinions and feedback on the need to keep NumPy from
> having a hard nose/pytest dependency. The options as I see them are:
> 
> pytest is never imported until the tests are run -- current practice
> with nose
> pytest is never imported unless the testfiles are imported -- what I
> would likeĀ 
> pytest is imported together when numpy is -- what we need to avoid.
> Currently the approach has been 1), but I think 2) makes more sense
> and allows more flexibility.


I am not quite sure about everything here. My guess is we can do
whatever we want when it comes to our own tests, and I don't mind just
switching everything to pytest (I for one am happy as long as I can run
`runtests.py` ;)).
When it comes to the utils we provide, those should keep working
without nose/pytest if they worked before without it I think.

My guess is that all your options do that, so I think we should take
the one that gives the nicest maintainable code :). Though can't say I
looked enough into it to really make a well educated decision, that
probably means your option 2.

- Sebastian



> Thoughts?
> Chuck
> ___
> NumPy-Discussion mailing list
> NumPy-Discussion@python.org
> https://mail.python.org/mailman/listinfo/numpy-discussion

signature.asc
Description: This is a digitally signed message part
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion


[Numpy-discussion] pytest and degrees of separation.

2017-07-11 Thread Charles R Harris
Hi All,

Just looking for opinions and feedback on the need to keep NumPy from
having a hard nose/pytest dependency. The options as I see them are:


   1. pytest is never imported until the tests are run -- current practice
   with nose
   2. pytest is never imported unless the testfiles are imported -- what I
   would like
   3. pytest is imported together when numpy is -- what we need to avoid.

Currently the approach has been 1), but I think 2) makes more sense and
allows more flexibility.

Thoughts?

Chuck
___
NumPy-Discussion mailing list
NumPy-Discussion@python.org
https://mail.python.org/mailman/listinfo/numpy-discussion