diff options
author | Cédric Ollivier <cedric.ollivier@orange.com> | 2017-07-02 12:56:09 +0200 |
---|---|---|
committer | Cédric Ollivier <cedric.ollivier@orange.com> | 2017-07-02 14:02:51 +0200 |
commit | 0ead7c9e03034bbb40b68a468a6deaa339b0364e (patch) | |
tree | 7002b06d6723b1569d4456547a69b04fb60b3203 /functest/tests/unit/cli/commands/test_cli_env.py | |
parent | 3dcd1e4db7540459d3dff337684547d68fea2b44 (diff) |
Update cli commands to call console scripts
Change-Id: I401879d7ec713b5307817da8b001838c35d9d731
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
Diffstat (limited to 'functest/tests/unit/cli/commands/test_cli_env.py')
-rw-r--r-- | functest/tests/unit/cli/commands/test_cli_env.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/functest/tests/unit/cli/commands/test_cli_env.py b/functest/tests/unit/cli/commands/test_cli_env.py index 0b18554b..ddd5d86c 100644 --- a/functest/tests/unit/cli/commands/test_cli_env.py +++ b/functest/tests/unit/cli/commands/test_cli_env.py @@ -6,7 +6,6 @@ # http://www.apache.org/licenses/LICENSE-2.0 import logging -import pkg_resources import unittest import mock @@ -25,8 +24,7 @@ class CliEnvTesting(unittest.TestCase): return_value=False) @mock.patch('functest.cli.commands.cli_testcase.ft_utils.execute_command') def test_prepare_default(self, mock_ft_utils, mock_os): - cmd = ("python %s start" % pkg_resources.resource_filename( - 'functest', 'ci/prepare_env.py')) + cmd = "prepare_env start" self.cli_environ.prepare() mock_ft_utils.assert_called_with(cmd) @@ -37,8 +35,7 @@ class CliEnvTesting(unittest.TestCase): with mock.patch('__builtin__.raw_input', return_value="y"), \ mock.patch('functest.cli.commands.cli_testcase.os.remove') \ as mock_os_remove: - cmd = ("python %s start" % pkg_resources.resource_filename( - 'functest', 'ci/prepare_env.py')) + cmd = "prepare_env start" self.cli_environ.prepare() mock_os_remove.assert_called_once_with( CONST.__getattribute__('env_active')) |