summaryrefslogtreecommitdiff
path: root/dev-python/argcomplete/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-12-15 18:09:03 +0000
committerV3n3RiX <venerix@redcorelinux.org>2019-12-15 18:09:03 +0000
commit7bc9c63c9da678a7e6fceb095d56c634afd22c56 (patch)
tree4a67d50a439e9af63947e5f8b6ba3719af98b6c9 /dev-python/argcomplete/files
parentb284a3168fa91a038925d2ecf5e4791011ea5e7d (diff)
gentoo resync : 15.12.2019
Diffstat (limited to 'dev-python/argcomplete/files')
-rw-r--r--dev-python/argcomplete/files/argcomplete-1.10.2-test-pythonpath.patch39
1 files changed, 39 insertions, 0 deletions
diff --git a/dev-python/argcomplete/files/argcomplete-1.10.2-test-pythonpath.patch b/dev-python/argcomplete/files/argcomplete-1.10.2-test-pythonpath.patch
new file mode 100644
index 000000000000..18bd22cf1893
--- /dev/null
+++ b/dev-python/argcomplete/files/argcomplete-1.10.2-test-pythonpath.patch
@@ -0,0 +1,39 @@
+From 003cc45b1fa45c766e38c3230423a5662a00d371 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= <mgorny@gentoo.org>
+Date: Thu, 21 Nov 2019 11:29:41 +0100
+Subject: [PATCH] Prepend to PYTHONPATH in test_console_script* instead of
+ replacing
+
+Modify _test_console_script() to prepend to PYTHONPATH instead of
+overwriting its value. This is necessary so that it is able to find
+just-built version of argcomplete that is provided via PYTHONPATH
+(vs requiring it to be installed in system-wide directory prior).
+
+Otherwise, the tests are failing:
+
+ Traceback (most recent call last):
+ File "./bin/test-package", line 5, in <module>
+ from test_package import main
+ File "/tmp/argcomplete/test_dir_pychyg9vqx/test_package/__init__.py", line 4, in <module>
+ import argcomplete
+ ModuleNotFoundError: No module named 'argcomplete'
+---
+ test/test.py | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/test/test.py b/test/test.py
+index 98da760..ddf5a03 100755
+--- a/test/test.py
++++ b/test/test.py
+@@ -1185,7 +1185,7 @@ class TestBashGlobal(TestBash):
+ with TempDir(prefix='test_dir_py', dir='.'):
+ self.sh.run_command('cd ' + os.getcwd())
+ self.sh.run_command('export PATH=$PATH:./bin')
+- self.sh.run_command('export PYTHONPATH=.')
++ self.sh.run_command('export PYTHONPATH=.:$PYTHONPATH')
+ test_package = os.path.join(TEST_DIR, 'test_package')
+ command = 'pip install {} --target .'.format(test_package)
+ if not wheel:
+--
+2.24.0
+