Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

virtualenv: allow tests to run properly on them #910

Merged
merged 1 commit into from Dec 7, 2015

Conversation

clebergnu
Copy link
Contributor

While going through the dependency list (requirements*.txt files) and
performing our self tests out of virtual environments, I noticed that
some tests are run outside the virtual environments.

The reason is that, even though the virtual environment is activated
for the test session (and say, which python gives /venv/bin/python),
we have hard coded /usr/bin/python in most places.

According to the some discussions on the virtualenv project itself[1],
a quick solution is to revert to the also common /usr/bin/env python
way of pointing to the Python interpreter.

[1] - pypa/virtualenv#124

Signed-off-by: Cleber Rosa crosa@redhat.com

While going through the dependency list (requirements*.txt files) and
performing our self tests out of virtual environments, I noticed that
some tests are run outside the virtual environments.

The reason is that, even though the virtual environment is activated
for the test session (and say, `which python` gives `/venv/bin/python`),
we have hard coded `/usr/bin/python` in most places.

According to the some discussions on the virtualenv project itself[1],
a quick solution is to revert to the also common `/usr/bin/env python`
way of pointing to the Python interpreter.

[1] - pypa/virtualenv#124

Signed-off-by: Cleber Rosa <crosa@redhat.com>
@lmr lmr added the in progress label Dec 7, 2015
@ldoktor
Copy link
Contributor

ldoktor commented Dec 7, 2015

Yep, good catch. I verified by fgrep that it covers all occurrences.

ldoktor added a commit that referenced this pull request Dec 7, 2015
virtualenv: allow tests to run properly on them
@ldoktor ldoktor merged commit d23e2fd into avocado-framework:master Dec 7, 2015
@lmr lmr removed the in progress label Dec 7, 2015
@clebergnu clebergnu deleted the usr_bin_env_python branch May 4, 2016 21:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants