1 |
commit: 48c2af4538d581fb2225c0ac9620b7fcfe4eae2e |
2 |
Author: Arfrever Frehtes Taifersar Arahesis <Arfrever <AT> Apache <DOT> Org> |
3 |
AuthorDate: Wed Dec 2 01:16:34 2015 +0000 |
4 |
Commit: Arfrever Frehtes Taifersar Arahesis <arfrever <AT> apache <DOT> org> |
5 |
CommitDate: Wed Dec 2 01:16:34 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=48c2af45 |
7 |
|
8 |
Respect PYTHONDONTWRITEBYTECODE in test suite. |
9 |
|
10 |
pym/portage/package/ebuild/_config/special_env_vars.py | 2 +- |
11 |
pym/portage/tests/dbapi/test_portdb_cache.py | 3 ++- |
12 |
pym/portage/tests/ebuild/test_doebuild_fd_pipes.py | 3 ++- |
13 |
pym/portage/tests/ebuild/test_doebuild_spawn.py | 3 ++- |
14 |
pym/portage/tests/ebuild/test_ipc_daemon.py | 3 ++- |
15 |
pym/portage/tests/emerge/test_config_protect.py | 3 ++- |
16 |
pym/portage/tests/emerge/test_emerge_slot_abi.py | 3 ++- |
17 |
pym/portage/tests/emerge/test_simple.py | 3 ++- |
18 |
pym/portage/tests/repoman/test_simple.py | 3 ++- |
19 |
pym/portage/tests/sync/test_sync_local.py | 3 ++- |
20 |
10 files changed, 19 insertions(+), 10 deletions(-) |
21 |
|
22 |
diff --git a/pym/portage/package/ebuild/_config/special_env_vars.py b/pym/portage/package/ebuild/_config/special_env_vars.py |
23 |
index 8479cf5..9ae53c1 100644 |
24 |
--- a/pym/portage/package/ebuild/_config/special_env_vars.py |
25 |
+++ b/pym/portage/package/ebuild/_config/special_env_vars.py |
26 |
@@ -77,7 +77,7 @@ environ_whitelist += [ |
27 |
"PORTAGE_SIGPIPE_STATUS", "PORTAGE_SOCKS5_PROXY", |
28 |
"PORTAGE_TMPDIR", "PORTAGE_UPDATE_ENV", "PORTAGE_USERNAME", |
29 |
"PORTAGE_VERBOSE", "PORTAGE_WORKDIR_MODE", "PORTAGE_XATTR_EXCLUDE", |
30 |
- "PORTDIR", "PORTDIR_OVERLAY", "PREROOTPATH", |
31 |
+ "PORTDIR", "PORTDIR_OVERLAY", "PREROOTPATH", "PYTHONDONTWRITEBYTECODE", |
32 |
"REPLACING_VERSIONS", "REPLACED_BY_VERSION", |
33 |
"ROOT", "ROOTPATH", "T", "TMP", "TMPDIR", |
34 |
"USE_EXPAND", "USE_ORDER", "WORKDIR", |
35 |
|
36 |
diff --git a/pym/portage/tests/dbapi/test_portdb_cache.py b/pym/portage/tests/dbapi/test_portdb_cache.py |
37 |
index 5ac9b03..bd93446 100644 |
38 |
--- a/pym/portage/tests/dbapi/test_portdb_cache.py |
39 |
+++ b/pym/portage/tests/dbapi/test_portdb_cache.py |
40 |
@@ -1,4 +1,4 @@ |
41 |
-# Copyright 2012-2014 Gentoo Foundation |
42 |
+# Copyright 2012-2015 Gentoo Foundation |
43 |
# Distributed under the terms of the GNU General Public License v2 |
44 |
|
45 |
import subprocess |
46 |
@@ -134,6 +134,7 @@ class PortdbCacheTestCase(TestCase): |
47 |
"PORTAGE_OVERRIDE_EPREFIX" : eprefix, |
48 |
"PORTAGE_PYTHON" : portage_python, |
49 |
"PORTAGE_REPOSITORIES" : settings.repositories.config_string(), |
50 |
+ "PYTHONDONTWRITEBYTECODE" : os.environ.get("PYTHONDONTWRITEBYTECODE", ""), |
51 |
"PYTHONPATH" : pythonpath, |
52 |
} |
53 |
|
54 |
|
55 |
diff --git a/pym/portage/tests/ebuild/test_doebuild_fd_pipes.py b/pym/portage/tests/ebuild/test_doebuild_fd_pipes.py |
56 |
index 61392dd..2a65537 100644 |
57 |
--- a/pym/portage/tests/ebuild/test_doebuild_fd_pipes.py |
58 |
+++ b/pym/portage/tests/ebuild/test_doebuild_fd_pipes.py |
59 |
@@ -1,4 +1,4 @@ |
60 |
-# Copyright 2013 Gentoo Foundation |
61 |
+# Copyright 2013-2015 Gentoo Foundation |
62 |
# Distributed under the terms of the GNU General Public License v2 |
63 |
|
64 |
import textwrap |
65 |
@@ -75,6 +75,7 @@ class DoebuildFdPipesTestCase(TestCase): |
66 |
settings.features.add("test") |
67 |
settings['PORTAGE_PYTHON'] = portage._python_interpreter |
68 |
settings['PORTAGE_QUIET'] = "1" |
69 |
+ settings['PYTHONDONTWRITEBYTECODE'] = os.environ.get("PYTHONDONTWRITEBYTECODE", "") |
70 |
|
71 |
fake_bin = os.path.join(settings["EPREFIX"], "bin") |
72 |
portage.util.ensure_dirs(fake_bin) |
73 |
|
74 |
diff --git a/pym/portage/tests/ebuild/test_doebuild_spawn.py b/pym/portage/tests/ebuild/test_doebuild_spawn.py |
75 |
index ae9a5c5..6b34465 100644 |
76 |
--- a/pym/portage/tests/ebuild/test_doebuild_spawn.py |
77 |
+++ b/pym/portage/tests/ebuild/test_doebuild_spawn.py |
78 |
@@ -1,4 +1,4 @@ |
79 |
-# Copyright 2010-2012 Gentoo Foundation |
80 |
+# Copyright 2010-2015 Gentoo Foundation |
81 |
# Distributed under the terms of the GNU General Public License v2 |
82 |
|
83 |
import textwrap |
84 |
@@ -65,6 +65,7 @@ class DoebuildSpawnTestCase(TestCase): |
85 |
settings['PORTAGE_PYTHON'] = _python_interpreter |
86 |
settings['PORTAGE_BUILDDIR'] = os.path.join( |
87 |
settings['PORTAGE_TMPDIR'], cpv) |
88 |
+ settings['PYTHONDONTWRITEBYTECODE'] = os.environ.get('PYTHONDONTWRITEBYTECODE', '') |
89 |
settings['T'] = os.path.join( |
90 |
settings['PORTAGE_BUILDDIR'], 'temp') |
91 |
for x in ('PORTAGE_BUILDDIR', 'T'): |
92 |
|
93 |
diff --git a/pym/portage/tests/ebuild/test_ipc_daemon.py b/pym/portage/tests/ebuild/test_ipc_daemon.py |
94 |
index a871076..835f51f 100644 |
95 |
--- a/pym/portage/tests/ebuild/test_ipc_daemon.py |
96 |
+++ b/pym/portage/tests/ebuild/test_ipc_daemon.py |
97 |
@@ -1,4 +1,4 @@ |
98 |
-# Copyright 2010-2012 Gentoo Foundation |
99 |
+# Copyright 2010-2015 Gentoo Foundation |
100 |
# Distributed under the terms of the GNU General Public License v2 |
101 |
|
102 |
import tempfile |
103 |
@@ -51,6 +51,7 @@ class IpcDaemonTestCase(TestCase): |
104 |
env['PORTAGE_BIN_PATH'] = PORTAGE_BIN_PATH |
105 |
env['PORTAGE_PYM_PATH'] = PORTAGE_PYM_PATH |
106 |
env['PORTAGE_BUILDDIR'] = os.path.join(tmpdir, 'cat', 'pkg-1') |
107 |
+ env['PYTHONDONTWRITEBYTECODE'] = os.environ.get('PYTHONDONTWRITEBYTECODE', '') |
108 |
|
109 |
if "__PORTAGE_TEST_HARDLINK_LOCKS" in os.environ: |
110 |
env["__PORTAGE_TEST_HARDLINK_LOCKS"] = \ |
111 |
|
112 |
diff --git a/pym/portage/tests/emerge/test_config_protect.py b/pym/portage/tests/emerge/test_config_protect.py |
113 |
index 5d7d8e9..06ab059 100644 |
114 |
--- a/pym/portage/tests/emerge/test_config_protect.py |
115 |
+++ b/pym/portage/tests/emerge/test_config_protect.py |
116 |
@@ -1,4 +1,4 @@ |
117 |
-# Copyright 2014 Gentoo Foundation |
118 |
+# Copyright 2014-2015 Gentoo Foundation |
119 |
# Distributed under the terms of the GNU General Public License v2 |
120 |
|
121 |
from __future__ import unicode_literals |
122 |
@@ -222,6 +222,7 @@ src_install() { |
123 |
"PORTAGE_PYTHON" : portage_python, |
124 |
"PORTAGE_REPOSITORIES" : settings.repositories.config_string(), |
125 |
"PORTAGE_TMPDIR" : portage_tmpdir, |
126 |
+ "PYTHONDONTWRITEBYTECODE" : os.environ.get("PYTHONDONTWRITEBYTECODE", ""), |
127 |
"PYTHONPATH" : pythonpath, |
128 |
"__PORTAGE_TEST_PATH_OVERRIDE" : fake_bin, |
129 |
} |
130 |
|
131 |
diff --git a/pym/portage/tests/emerge/test_emerge_slot_abi.py b/pym/portage/tests/emerge/test_emerge_slot_abi.py |
132 |
index d1f2d92..2006993 100644 |
133 |
--- a/pym/portage/tests/emerge/test_emerge_slot_abi.py |
134 |
+++ b/pym/portage/tests/emerge/test_emerge_slot_abi.py |
135 |
@@ -1,4 +1,4 @@ |
136 |
-# Copyright 2012-2014 Gentoo Foundation |
137 |
+# Copyright 2012-2015 Gentoo Foundation |
138 |
# Distributed under the terms of the GNU General Public License v2 |
139 |
|
140 |
import subprocess |
141 |
@@ -119,6 +119,7 @@ class SlotAbiEmergeTestCase(TestCase): |
142 |
"PATH" : path, |
143 |
"PORTAGE_PYTHON" : portage_python, |
144 |
"PORTAGE_REPOSITORIES" : settings.repositories.config_string(), |
145 |
+ "PYTHONDONTWRITEBYTECODE" : os.environ.get("PYTHONDONTWRITEBYTECODE", ""), |
146 |
"PYTHONPATH" : pythonpath, |
147 |
} |
148 |
|
149 |
|
150 |
diff --git a/pym/portage/tests/emerge/test_simple.py b/pym/portage/tests/emerge/test_simple.py |
151 |
index 0101362..394ed43 100644 |
152 |
--- a/pym/portage/tests/emerge/test_simple.py |
153 |
+++ b/pym/portage/tests/emerge/test_simple.py |
154 |
@@ -1,4 +1,4 @@ |
155 |
-# Copyright 2011-2014 Gentoo Foundation |
156 |
+# Copyright 2011-2015 Gentoo Foundation |
157 |
# Distributed under the terms of the GNU General Public License v2 |
158 |
|
159 |
import subprocess |
160 |
@@ -369,6 +369,7 @@ pkg_preinst() { |
161 |
"PORTAGE_PYTHON" : portage_python, |
162 |
"PORTAGE_REPOSITORIES" : settings.repositories.config_string(), |
163 |
"PORTAGE_TMPDIR" : portage_tmpdir, |
164 |
+ "PYTHONDONTWRITEBYTECODE" : os.environ.get("PYTHONDONTWRITEBYTECODE", ""), |
165 |
"PYTHONPATH" : pythonpath, |
166 |
"__PORTAGE_TEST_PATH_OVERRIDE" : fake_bin, |
167 |
} |
168 |
|
169 |
diff --git a/pym/portage/tests/repoman/test_simple.py b/pym/portage/tests/repoman/test_simple.py |
170 |
index f41f057..af6f95d 100644 |
171 |
--- a/pym/portage/tests/repoman/test_simple.py |
172 |
+++ b/pym/portage/tests/repoman/test_simple.py |
173 |
@@ -1,4 +1,4 @@ |
174 |
-# Copyright 2011-2014 Gentoo Foundation |
175 |
+# Copyright 2011-2015 Gentoo Foundation |
176 |
# Distributed under the terms of the GNU General Public License v2 |
177 |
|
178 |
import subprocess |
179 |
@@ -229,6 +229,7 @@ class SimpleRepomanTestCase(TestCase): |
180 |
"PORTAGE_GRPNAME" : os.environ["PORTAGE_GRPNAME"], |
181 |
"PORTAGE_USERNAME" : os.environ["PORTAGE_USERNAME"], |
182 |
"PORTAGE_REPOSITORIES" : settings.repositories.config_string(), |
183 |
+ "PYTHONDONTWRITEBYTECODE" : os.environ.get("PYTHONDONTWRITEBYTECODE", ""), |
184 |
"PYTHONPATH" : pythonpath, |
185 |
} |
186 |
|
187 |
|
188 |
diff --git a/pym/portage/tests/sync/test_sync_local.py b/pym/portage/tests/sync/test_sync_local.py |
189 |
index 7753a26..b57bdba 100644 |
190 |
--- a/pym/portage/tests/sync/test_sync_local.py |
191 |
+++ b/pym/portage/tests/sync/test_sync_local.py |
192 |
@@ -1,4 +1,4 @@ |
193 |
-# Copyright 2014 Gentoo Foundation |
194 |
+# Copyright 2014-2015 Gentoo Foundation |
195 |
# Distributed under the terms of the GNU General Public License v2 |
196 |
|
197 |
import subprocess |
198 |
@@ -194,6 +194,7 @@ class SyncLocalTestCase(TestCase): |
199 |
"PATH" : os.environ["PATH"], |
200 |
"PORTAGE_GRPNAME" : os.environ["PORTAGE_GRPNAME"], |
201 |
"PORTAGE_USERNAME" : os.environ["PORTAGE_USERNAME"], |
202 |
+ "PYTHONDONTWRITEBYTECODE" : os.environ.get("PYTHONDONTWRITEBYTECODE", ""), |
203 |
"PYTHONPATH" : pythonpath, |
204 |
} |
205 |
repos_set_conf("rsync") |