Nilesh Patra pushed to branch master at Debian Med / nibabel
Commits: 0b2012a1 by Nilesh Patra at 2020-07-27T19:58:10+05:30 Switch autopkgtest to pytest - - - - - 58dd2e8b by Nilesh Patra at 2020-07-27T19:58:10+05:30 Remove TODO - - - - - 3f975aec by Nilesh Patra at 2020-07-27T20:00:33+05:30 Fix lintian - - - - - b8ea5dc7 by Nilesh Patra at 2020-07-27T20:01:56+05:30 compat version: 13 - - - - - 77ad62a3 by Nilesh Patra at 2020-07-27T20:17:42+05:30 Fix perms of non-executables - - - - - 6 changed files: - debian/control - + debian/python-nibabel-doc.lintian-overrides - debian/rules - debian/tests/control - − debian/tests/nosetests3 - + debian/tests/run-unit-test Changes: ===================================== debian/control ===================================== @@ -4,7 +4,7 @@ Uploaders: Michael Hanke <[email protected]>, Yaroslav Halchenko <[email protected]> Section: python Priority: optional -Build-Depends: debhelper-compat (= 12), +Build-Depends: debhelper-compat (= 13), dh-python, python3-fuse, python3-bz2file, @@ -26,8 +26,7 @@ Standards-Version: 4.5.0 Vcs-Browser: https://salsa.debian.org/med-team/nibabel Vcs-Git: https://salsa.debian.org/med-team/nibabel.git Homepage: https://nipy.org/nibabel/ -#FIXME: See dirty hack in d/rules -#Rules-Requires-Root: no +Rules-Requires-Root: no Package: python3-nibabel Architecture: all ===================================== debian/python-nibabel-doc.lintian-overrides ===================================== @@ -0,0 +1 @@ +python-nibabel-doc: embedded-javascript-library * ===================================== debian/rules ===================================== @@ -12,15 +12,7 @@ export MPLCONFIGDIR=$(CURDIR)/build override_dh_auto_build: dh_auto_build - # and docs - # FIXME: Really dirty hack to avoid - # Exception occurred: - # File "/usr/lib/python3/dist-packages/matplotlib/__init__.py", line 776, in _open_file_or_url - # with open(fname, encoding=encoding) as f: - # FileNotFoundError: [Errno 2] No such file or directory: '/usr/share/matplotlib/mpl-data/matplotlibrc' - # This does not even work - # cp /etc/matplotlibrc /usr/share/matplotlib/mpl-data/ - PYTHONPATH=$(CURDIR) $(MAKE) -C doc html SPHINXBUILD=/usr/share/sphinx/scripts/python3/sphinx-build PYTHON=python3 || true + PYTHONPATH=$(CURDIR) $(MAKE) -C doc html SPHINXBUILD=/usr/share/sphinx/scripts/python3/sphinx-build PYTHON=python3 # but remove jquery copy (later on link to Debian's version) -rm build/html/_static/jquery.js # objects inventory is of no use for the package @@ -51,6 +43,11 @@ override_dh_installman: dh_installman build/*.1 +override_dh_fixperms: + find debian/ -name 'gzipbase64.gii' | xargs chmod -x + find debian/ -name 'umass_anonymized.PAR' | xargs chmod -x + dh_fixperms + override_dh_clean: $(MAKE) clean dh_clean ===================================== debian/tests/control ===================================== @@ -1,2 +1,2 @@ -Tests: nosetests3 -Depends: python3-all, python3-nose, python3-numpy, python3-scipy, python3-six, python3-nibabel +Tests: run-unit-test +Depends: python3-all, python3-pytest, python3-nose, python3-numpy, python3-scipy, python3-six ===================================== debian/tests/nosetests3 deleted ===================================== @@ -1,33 +0,0 @@ -#!/bin/bash -# -# ADT test executioner for python-* packages. -# Should be usable with any module which uses nosetests and packaged -# as python-MODULENAME. To use for Python3, just symlink as nosetests3 -# -# Version: 1.1 -# -set -efu - -test_exec="$0" -test_name=$(basename "$test_exec") -test_path=$(readlink -f $0 | xargs dirname) - -# which tester to use is defined by the name -tester=${test_name%%[0-9]} -# Figure out for which version of Python this test runner was intended -py_series=$(echo $test_exec | sed -e 's,.*\([0-9]\)$,\1,g') -# Construct optional PY suffix which is empty for good old python2 -[ $py_series = '2' ] && PY='' || PY=$py_series - -# Figure out what is the name of the module we are testing -py_module=$(sed -ne '/^Package: python/s,.*python-\(.*\),\1,gp' $test_path/../control \ - | grep -v -e '-\(doc\|dbg\|lib\)' | head -n 1) - -pys="$(eval py${PY}versions -rv 2>/dev/null)" - -cd "$AUTOPKGTEST_TMP" - -for py in $pys; do - echo "=== python$py ===" - python$py /usr/bin/$tester$PY ${TESTER_ARGS:-} $py_module 2>&1 -done ===================================== debian/tests/run-unit-test ===================================== @@ -0,0 +1,8 @@ +#!/bin/bash +set -efu + +for py in $(py3versions -r 2> /dev/null) +do + $py -m pytest -v +done + View it on GitLab: https://salsa.debian.org/med-team/nibabel/-/compare/669d0cbed937db2bae004a4dda09b03cca2b734c...77ad62a397e061359e10d00af2602ef527229421 -- View it on GitLab: https://salsa.debian.org/med-team/nibabel/-/compare/669d0cbed937db2bae004a4dda09b03cca2b734c...77ad62a397e061359e10d00af2602ef527229421 You're receiving this email because of your account on salsa.debian.org.
_______________________________________________ debian-med-commit mailing list [email protected] https://alioth-lists.debian.net/cgi-bin/mailman/listinfo/debian-med-commit
