[Matplotlib-devel] Fwd: our tests
Elliott Sales de Andrade
quantum.analyst at gmail.com
Sat Jan 28 15:46:58 EST 2017
Hi Eric,
Sorry if you receive this twice.
On 24 November 2016 at 18:49, Eric Firing <efiring.ocean at gmail.com> wrote:
> Does anyone know why:
>
> 1) In our Travis suite, the USE_PYTEST run takes much longer than the
> others.
>
>
Nelle has answered this one already.
> 2) On master (approximately), when I try to run a single function with
> py.test, it isn't found. Example:
>
> py.test lib/matplotlib/tests/test_axes.py::test_hist_steplog
> =============================================== test session starts
> ================================================
> platform darwin -- Python 3.5.1, pytest-2.8.5, py-1.4.31, pluggy-0.3.1
> rootdir: /Users/efiring/work/programs/py/mpl/matplotlib, inifile:
> pytest.ini
> collecting 530 items
> =========================================== no tests ran in 0.39 seconds
> ===========================================
> ERROR: not found: /Users/efiring/work/programs/p
> y/mpl/matplotlib/lib/matplotlib/tests/test_axes.py::test_hist_steplog
> (no name '/Users/efiring/work/programs/py/mpl/matplotlib/lib/matplotl
> ib/tests/test_axes.py::test_hist_steplog' in any of [<Module
> 'lib/matplotlib/tests/test_axes.py'>])
>
>
This works for me; I think you need to update your version of pytest:
py.test lib/matplotlib/tests/test_axes.py::test_hist_steplog
============================= test session starts
=============================
platform linux -- Python 3.5.2, pytest-3.0.3, py-1.4.31, pluggy-0.4.0
rootdir: /home/elliott/code/matplotlib, inifile: pytest.ini
collected 505 items
lib/matplotlib/tests/test_axes.py ...
========================== 3 passed in 3.78 seconds
===========================
Note, there are 3 tests because of the 3 extensions that are checked by the
image_comparison decorator.
> 3) Also on master, I get errors with tests.py. Example:
>
> python tests.py lib/matplotlib/tests/test_axes.py
>
> [snip]
>
>
>
This will not work at the moment. tests.py continues to use nose, so it
will not run pytest-based files. The list of files that only work with nose
is very short right now. As soon as my other PR is merged, I will open a PR
that should make this work again (there are conflicts).
--
Elliott
--
Elliott
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/matplotlib-devel/attachments/20170128/c6624bf4/attachment-0001.html>
More information about the Matplotlib-devel
mailing list