From 16f350cb685bbf882aceed50b5b96d2cf7f2bc11 Mon Sep 17 00:00:00 2001 From: Sebastian Kalinowski Date: Tue, 20 Jan 2015 15:22:54 +0100 Subject: [PATCH] Fix calling fuelclient during tests Instead of building path to 'fuel' executable (which causes issues on CI server) simply call 'fuel' since it is added to PATH in tox environment. Change-Id: I14a3c42fac084d7b3d6cb9b26e9c4f23ec60b02b --- fuelclient/tests/base.py | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/fuelclient/tests/base.py b/fuelclient/tests/base.py index 906f7b4..225098d 100644 --- a/fuelclient/tests/base.py +++ b/fuelclient/tests/base.py @@ -63,22 +63,10 @@ class UnitTestCase(TestCase): class BaseTestCase(UnitTestCase): - root_path = os.path.abspath( - os.path.join( - os.curdir, - os.path.pardir - ) - ) - nailgun_root = os.environ.get('NAILGUN_ROOT', '/tmp/fuel_web/nailgun') manage_path = os.path.join(nailgun_root, 'manage.py') - fuel_path = os.path.join( - root_path, - "python-fuelclient/fuel" - ) - def setUp(self): self.reload_nailgun_server() self.temp_directory = tempfile.mkdtemp() @@ -118,7 +106,7 @@ class BaseTestCase(UnitTestCase): def run_cli_command(self, command_line, check_errors=False): modified_env = os.environ.copy() - command_args = [" ".join((self.fuel_path, command_line))] + command_args = [" ".join(('fuel', command_line))] process_handle = subprocess.Popen( command_args, stdout=subprocess.PIPE,