summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/pyparted/fix-test-pythonpath.patch
diff options
context:
space:
mode:
authorLancelot SIX <lsix@lancelotsix.com>2020-02-18 20:19:16 +0100
committerJon <jonringer@users.noreply.github.com>2020-02-18 14:03:41 -0800
commit490615ef6308041a22cc2a377fdbfd3c2ca31c7f (patch)
treed01a18e8ada1fb884c1e10b18dd4d1d1a7ccfb89 /pkgs/development/python-modules/pyparted/fix-test-pythonpath.patch
parent3f448f08aa082b5698e0697dd2224c0d2b4db509 (diff)
pythonPackages.pyparted: 3.10.4 -> 3.11.4
Diffstat (limited to 'pkgs/development/python-modules/pyparted/fix-test-pythonpath.patch')
-rw-r--r--pkgs/development/python-modules/pyparted/fix-test-pythonpath.patch26
1 files changed, 26 insertions, 0 deletions
diff --git a/pkgs/development/python-modules/pyparted/fix-test-pythonpath.patch b/pkgs/development/python-modules/pyparted/fix-test-pythonpath.patch
new file mode 100644
index 000000000000..740bffbef6d8
--- /dev/null
+++ b/pkgs/development/python-modules/pyparted/fix-test-pythonpath.patch
@@ -0,0 +1,26 @@
+diff -ur a/Makefile b/Makefile
+--- a/Makefile 1980-01-02 00:00:00.000000000 +0100
++++ b/Makefile 2020-02-18 20:04:14.068243263 +0100
+@@ -39,19 +39,19 @@
+ @$(PYTHON) setup.py build
+
+ test: all
+- @env PYTHONPATH=$$(find $$(pwd) -name "*.so" | head -n 1 | xargs dirname):src/parted:src \
++ @env PYTHONPATH=$$(find $$(pwd) -name "*.so" | head -n 1 | xargs dirname):src/parted:src:$$PYTHONPATH \
+ $(PYTHON) -m unittest discover -v
+
+ coverage: all
+ @echo "*** Running unittests with $(COVERAGE) for $(PYTHON) ***"
+- @env PYTHONPATH=$$(find $$(pwd) -name "*.so" | head -n 1 | xargs dirname):src/parted:src \
++ @env PYTHONPATH=$$(find $$(pwd) -name "*.so" | head -n 1 | xargs dirname):src/parted:src:$$PYTHONPATH \
+ $(COVERAGE) run --branch -m unittest discover -v
+ $(COVERAGE) report --include="build/lib.*/parted/*" --show-missing
+ $(COVERAGE) report --include="build/lib.*/parted/*" > coverage-report.log
+
+ check: clean
+ env PYTHON=python3 $(MAKE) ; \
+- env PYTHON=python3 PYTHONPATH=$$(find $$(pwd) -name "*.so" | head -n 1 | xargs dirname):src/parted:src \
++ env PYTHON=python3 PYTHONPATH=$$(find $$(pwd) -name "*.so" | head -n 1 | xargs dirname):src/parted:src:$$PYTHONPATH \
+ tests/pylint/runpylint.py
+
+ dist: