diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2019-12-15 18:09:03 +0000 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2019-12-15 18:09:03 +0000 |
commit | 7bc9c63c9da678a7e6fceb095d56c634afd22c56 (patch) | |
tree | 4a67d50a439e9af63947e5f8b6ba3719af98b6c9 /dev-python/sh/files | |
parent | b284a3168fa91a038925d2ecf5e4791011ea5e7d (diff) |
gentoo resync : 15.12.2019
Diffstat (limited to 'dev-python/sh/files')
-rw-r--r-- | dev-python/sh/files/sh-1.12.14-skip-unreliable-test.patch | 12 | ||||
-rw-r--r-- | dev-python/sh/files/sh-1.12.14-tests.patch | 43 |
2 files changed, 55 insertions, 0 deletions
diff --git a/dev-python/sh/files/sh-1.12.14-skip-unreliable-test.patch b/dev-python/sh/files/sh-1.12.14-skip-unreliable-test.patch new file mode 100644 index 000000000000..aa4f75727a17 --- /dev/null +++ b/dev-python/sh/files/sh-1.12.14-skip-unreliable-test.patch @@ -0,0 +1,12 @@ +diff --git a/test.py b/test.py +index 68ef40c..e5d48da 100644 +--- a/test.py ++++ b/test.py +@@ -500,2 +500,3 @@ while True: + ++ @unittest.skip("Test is unreliable") + def test_environment(self): +@@ -587,2 +588,3 @@ exit(2) + ++ @unittest.skip("Test seems to be unreliable") + def test_piped_exception1(self): diff --git a/dev-python/sh/files/sh-1.12.14-tests.patch b/dev-python/sh/files/sh-1.12.14-tests.patch new file mode 100644 index 000000000000..bc3d1b59fef6 --- /dev/null +++ b/dev-python/sh/files/sh-1.12.14-tests.patch @@ -0,0 +1,43 @@ +diff --git a/test.py b/test.py +index 68ef40c..640e5b5 100644 +--- a/test.py ++++ b/test.py +@@ -515,6 +515,13 @@ def test_environment(self): + "VERSIONER_PYTHON_VERSION", + ] + ++ # On python-3.7+, the changes for no encoding inject LC_CTYPE into subprocesses ++ py37_extra_envvars = [ ++ "LC_CTYPE", ++ ] ++ ++ prune_envvars = osx_cruft + py37_extra_envvars ++ + # first we test that the environment exists in our child process as + # we've set it + py = create_tmp_test(""" +@@ -525,7 +532,7 @@ def test_environment(self): + try: del os.environ[key] + except: pass + print(os.environ["HERP"] + " " + str(len(os.environ))) +-""" % osx_cruft) ++""" % prune_envvars) + out = python(py.name, _env=env).strip() + self.assertEqual(out, "DERP 1") + +@@ -533,12 +540,12 @@ def test_environment(self): + import os, sys + sys.path.insert(0, os.getcwd()) + import sh +-osx_cruft = %s +-for key in osx_cruft: ++prune_envvars = %s ++for key in prune_envvars: + try: del os.environ[key] + except: pass + print(sh.HERP + " " + str(len(os.environ))) +-""" % osx_cruft) ++""" % prune_envvars) + out = python(py.name, _env=env, _cwd=THIS_DIR).strip() + self.assertEqual(out, "DERP 1") + |