Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.maint.python > #10889
| Path | csiph.com!feeder.erje.net!1.eu.feeder.erje.net!newsfeed.CARNet.hr!news.spin.it!bofh.it!news.nic.it!robomod |
|---|---|
| From | Ole Streicher <olebole@debian.org> |
| Newsgroups | linux.debian.maint.python |
| Subject | Problem with pybuild and pytest |
| Date | Thu, 13 Sep 2018 10:40:01 +0200 |
| Message-ID | <wxvkl-1GZ-19@gated-at.bofh.it> (permalink) |
| X-Mailbox-Line | From debian-python-request@lists.debian.org Thu Sep 13 08:36:10 2018 |
| Old-Return-Path | <news@liska.ath.cx> |
| X-Amavis-Spam-Status | No, score=-6.999 tagged_above=-10000 required=5.3 tests=[BAYES_00=-2, HEADER_FROM_DIFFERENT_DOMAINS=0.001, LDO_WHITELIST=-5] autolearn=ham autolearn_force=no |
| X-Policyd-Weight | using cached result; rate: -7 |
| User-Agent | Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) |
| MIME-Version | 1.0 |
| Content-Type | text/plain |
| Lines | 59 |
| X-Mailing-List | <debian-python@lists.debian.org> archive/latest/16315 |
| List-ID | <debian-python.lists.debian.org> |
| List-URL | <https://lists.debian.org/debian-python/> |
| List-Archive | https://lists.debian.org/msgid-search/874let3j2i.fsf@debian.org |
| Approved | robomod@news.nic.it |
| Organization | linux.* mail to news gateway |
| Sender | robomod@news.nic.it |
| X-Original-Date | Thu, 13 Sep 2018 10:20:05 +0200 |
| X-Original-Message-ID | <874let3j2i.fsf@debian.org> |
| Xref | csiph.com linux.debian.maint.python:10889 |
Show key headers only | View raw
Hi,
For one of my packages (sunpy), I want to complete the switch to pybuild
by removing the custom (and quite unperfect) dh_override_auto_test rule.
Currently, I have the following lines in d/rules:
override_dh_auto_test:
python -m pytest sunpy -k "not figure and not online"
python3 -m pytest sunpy -k "not figure and not online"
This gives successfull tests with the following output in the log:
--------------------------8<-------------------------------------------
debian/rules override_dh_auto_test
make[1]: Entering directory '/<<PKGBUILDDIR>>'
pyversions: missing X(S)-Python-Version in control file, fall back to debian/pyversions
pyversions: missing debian/pyversions file, fall back to supported versions
pyversions: missing X(S)-Python-Version in control file, fall back to debian/pyversions
pyversions: missing debian/pyversions file, fall back to supported versions
python -m pytest sunpy -k "not figure and not online"
============================= test session starts ==============================
platform linux2 -- Python 2.7.15, pytest-3.6.4, py-1.5.4, pluggy-0.6.0
rootdir: /<<PKGBUILDDIR>>, inifile: setup.cfg
plugins: mock-1.7.1, hypothesis-3.44.1
collected 1448 items / 34 deselected
[...]
--------------------------8<-------------------------------------------
>From the pybuild wiki page, I learned to do instead the override:
export PYBUILD_TEST_ARGS=-k "not figure and not online"
However, then the tests are not found anymore and the test step fails:
--------------------------8<-------------------------------------------
dh_auto_test -O--buildsystem=pybuild
I: pybuild base:217: cd /build/sunpy-0.9.3/.pybuild/cpython2_2.7_sunpy/build; python2.7 -m pytest -k "not figure and not online"
============================= test session starts ==============================
platform linux2 -- Python 2.7.15+, pytest-3.6.4, py-1.6.0, pluggy-0.6.0
rootdir: /build/sunpy-0.9.3, inifile: setup.cfg
plugins: mock-1.7.1, hypothesis-3.44.1
collected 0 items
========================= no tests ran in 0.00 seconds =========================
E: pybuild pybuild:338: test: plugin distutils failed with: exit code=5: cd /build/sunpy-0.9.3/.pybuild/cpython2_2.7_sunpy/build; python2.7 -m pytest -k "not figure and not online"
dh_auto_test: pybuild --test --test-pytest -i python{version} -p 2.7 returned exit code 13
--------------------------8<-------------------------------------------
I don't understand why the tests fail now? How do I correctly specify
them?
Best regards
Ole
Back to linux.debian.maint.python | Previous | Next | Find similar | Unroll thread
Problem with pybuild and pytest Ole Streicher <olebole@debian.org> - 2018-09-13 10:40 +0200
csiph-web