Commit dce7b95b authored by Jérome Perrin's avatar Jérome Perrin

slapos/testing: unset PYTHONPATH in CrontabMixin

When we execute crontab commands, these commands might be python scripts, so
we don't want the PYTHONPATH set by `python setup.py test` to apply to these
scripts.
parent 663e4975
......@@ -217,7 +217,8 @@ class CrontabMixin(object):
"""
crontab_command = self._getCrontabCommand(crontab_name)
subprocess.check_call(
"faketime {date} bash -o pipefail -e -c '{crontab_command}'".format(**locals()),
# XXX we unset PYTHONPATH set by `setup.py test`
"env PYTHONPATH= faketime {date} bash -o pipefail -e -c '{crontab_command}'".format(**locals()),
shell=True,
)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment