summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGiampaolo Rodola <g.rodola@gmail.com>2016-12-12 00:18:43 +0100
committerGiampaolo Rodola <g.rodola@gmail.com>2016-12-12 00:18:43 +0100
commitd0d3b182f7e4d1e988bad696880bb884c54a31f6 (patch)
treebc36f42b0679c3f9a3bf17d9609f5a283e94882d
parent07c9a4850202eadf5c920ee2644c7d669851945f (diff)
downloadpsutil-d0d3b182f7e4d1e988bad696880bb884c54a31f6.tar.gz
update docstring
-rw-r--r--psutil/tests/__init__.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/psutil/tests/__init__.py b/psutil/tests/__init__.py
index 883d9285..b119a788 100644
--- a/psutil/tests/__init__.py
+++ b/psutil/tests/__init__.py
@@ -506,6 +506,7 @@ def chdir(dirname):
def create_exe(outpath, c_code=None):
+ """Creates an executable file in the given location."""
assert not os.path.exists(outpath), outpath
if which("gcc"):
if c_code is None:
@@ -526,6 +527,9 @@ def create_exe(outpath, c_code=None):
safe_rmpath(f.name)
else:
# fallback - use python's executable
+ if c_code is not None:
+ raise ValueError(
+ "can't specify c_code arg as gcc is not installed")
shutil.copyfile(sys.executable, outpath)
if POSIX:
st = os.stat(outpath)