diff options
author | Cédric Ollivier <cedric.ollivier@orange.com> | 2017-06-30 06:24:11 +0200 |
---|---|---|
committer | Cédric Ollivier <cedric.ollivier@orange.com> | 2017-06-30 14:32:52 +0200 |
commit | 678609610f4ccbcb19438cbce5d84bd376010596 (patch) | |
tree | f79c8abd8f04d99e586317e426fc05a68992badf /functest/tests/unit/ci/test_prepare_env.py | |
parent | c426ee40d40434ea3a5d085f7b98d28fcdb063ff (diff) |
Define console_scripts
Only prepare_env.py and run_tests.py remain executable to avoid
breaking the gate.
As soon as the jenkins jobs are updated to run them from $PATH, tox
will be updated to protect against chmod a+x py files. Dockerfile
will be simplified as well.
Change-Id: Iac1a7ceb6b344e800177226ea39919826f6d3735
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
Diffstat (limited to 'functest/tests/unit/ci/test_prepare_env.py')
-rw-r--r-- | functest/tests/unit/ci/test_prepare_env.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/functest/tests/unit/ci/test_prepare_env.py b/functest/tests/unit/ci/test_prepare_env.py index 69abd643..7d4b5fb2 100644 --- a/functest/tests/unit/ci/test_prepare_env.py +++ b/functest/tests/unit/ci/test_prepare_env.py @@ -441,7 +441,7 @@ class PrepareEnvTesting(unittest.TestCase): mock_check_env): with mock.patch("__builtin__.open", mock.mock_open()) as m: args = {'action': 'start'} - self.assertEqual(prepare_env.main(**args), 0) + self.assertEqual(prepare_env.prepare_env(**args), 0) mock_logger_info.assert_any_call("######### Preparing Functest " "environment #########\n") self.assertTrue(mock_env_var.called) @@ -459,13 +459,13 @@ class PrepareEnvTesting(unittest.TestCase): @mock.patch('functest.ci.prepare_env.check_environment') def test_main_check(self, mock_check_env): args = {'action': 'check'} - self.assertEqual(prepare_env.main(**args), 0) + self.assertEqual(prepare_env.prepare_env(**args), 0) self.assertTrue(mock_check_env.called) @mock.patch('functest.ci.prepare_env.logger.error') def test_main_no_arg(self, mock_logger_error): args = {'action': 'not_valid'} - self.assertEqual(prepare_env.main(**args), -1) + self.assertEqual(prepare_env.prepare_env(**args), -1) mock_logger_error.assert_called_once_with('Argument not valid.') |