diff options
| author | Duncan McGreggor <duncan@dreamhost.com> | 2011-12-07 15:20:55 -0800 |
|---|---|---|
| committer | Duncan McGreggor <duncan@dreamhost.com> | 2011-12-07 15:26:14 -0800 |
| commit | ac0ac446aaa0af517a2b726e48d3b37eeffd46e5 (patch) | |
| tree | 7c7f16d35e1bf2217303ca4c57804ea6dab89b12 /nova | |
| parent | 9985d1f9517f47fb514e5a8997e06a85af631f62 (diff) | |
| download | nova-ac0ac446aaa0af517a2b726e48d3b37eeffd46e5.tar.gz nova-ac0ac446aaa0af517a2b726e48d3b37eeffd46e5.tar.xz nova-ac0ac446aaa0af517a2b726e48d3b37eeffd46e5.zip | |
Updated the test runner module with a sys.path insert so that tests run in and
outside a virtual environment.
This addresses bug 901387
Change-Id: I12a2b1eeaf0ce46796af6e42fd6537bccd6a4d8f
Diffstat (limited to 'nova')
| -rw-r--r-- | nova/testing/runner.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/nova/testing/runner.py b/nova/testing/runner.py index 9fbbb418d..794fa3845 100644 --- a/nova/testing/runner.py +++ b/nova/testing/runner.py @@ -63,13 +63,16 @@ import unittest import sys import time -gettext.install('nova', unicode=1) - import eventlet from nose import config from nose import core from nose import result +gettext.install('nova', unicode=1) +reldir = os.path.join(os.path.dirname(__file__), '..', '..') +absdir = os.path.abspath(reldir) +sys.path.insert(0, absdir) + from nova import log as logging |
