diff options
Diffstat (limited to 'functest/tests/unit')
-rw-r--r-- | functest/tests/unit/core/test_feature.py | 4 | ||||
-rw-r--r-- | functest/tests/unit/core/test_testcase.py | 81 | ||||
-rw-r--r-- | functest/tests/unit/core/test_vnf_base.py | 2 | ||||
-rw-r--r-- | functest/tests/unit/odl/test_odl.py | 2 | ||||
-rw-r--r-- | functest/tests/unit/openstack/__init__.py (renamed from functest/tests/unit/opnfv_tests/__init__.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/openstack/rally/__init__.py (renamed from functest/tests/unit/opnfv_tests/openstack/__init__.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/openstack/rally/test_rally.py (renamed from functest/tests/unit/opnfv_tests/openstack/rally/test_rally.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/openstack/refstack_client/__init__.py (renamed from functest/tests/unit/opnfv_tests/openstack/rally/__init__.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/openstack/refstack_client/test_refstack_client.py (renamed from functest/tests/unit/opnfv_tests/openstack/refstack_client/test_refstack_client.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/openstack/tempest/__init__.py (renamed from functest/tests/unit/opnfv_tests/openstack/refstack_client/__init__.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/openstack/tempest/test_conf_utils.py (renamed from functest/tests/unit/opnfv_tests/openstack/tempest/test_conf_utils.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/openstack/tempest/test_tempest.py (renamed from functest/tests/unit/opnfv_tests/openstack/tempest/test_tempest.py) | 168 | ||||
-rw-r--r-- | functest/tests/unit/opnfv_tests/vnf/__init__.py | 0 | ||||
-rw-r--r-- | functest/tests/unit/opnfv_tests/vnf/ims/__init__.py | 0 | ||||
-rw-r--r-- | functest/tests/unit/utils/test_functest_utils.py | 16 | ||||
-rw-r--r-- | functest/tests/unit/vnf/ims/__init__.py (renamed from functest/tests/unit/opnfv_tests/openstack/tempest/__init__.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/vnf/ims/test_clearwater.py (renamed from functest/tests/unit/opnfv_tests/vnf/ims/test_clearwater.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/vnf/ims/test_cloudify_ims.py (renamed from functest/tests/unit/opnfv_tests/vnf/ims/test_cloudify_ims.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/vnf/ims/test_ims_base.py (renamed from functest/tests/unit/opnfv_tests/vnf/ims/test_ims_base.py) | 0 | ||||
-rw-r--r-- | functest/tests/unit/vnf/ims/test_orchestrator_cloudify.py (renamed from functest/tests/unit/opnfv_tests/vnf/ims/test_orchestrator_cloudify.py) | 0 |
20 files changed, 153 insertions, 120 deletions
diff --git a/functest/tests/unit/core/test_feature.py b/functest/tests/unit/core/test_feature.py index bd7197f0..993da5a0 100644 --- a/functest/tests/unit/core/test_feature.py +++ b/functest/tests/unit/core/test_feature.py @@ -35,9 +35,9 @@ class FeatureTestingBase(unittest.TestCase): def _test_run(self, status, mock_method=None): self.assertEqual(self.feature.run(cmd=self._cmd), status) if status == testcase.TestCase.EX_OK: - self.assertEqual(self.feature.criteria, 'PASS') + self.assertEqual(self.feature.result, 100) else: - self.assertEqual(self.feature.criteria, 'FAIL') + self.assertEqual(self.feature.result, 0) mock_method.assert_has_calls([mock.call(), mock.call()]) self.assertEqual(self.feature.start_time, 1) self.assertEqual(self.feature.stop_time, 2) diff --git a/functest/tests/unit/core/test_testcase.py b/functest/tests/unit/core/test_testcase.py index 4f3b25cc..cc8446d8 100644 --- a/functest/tests/unit/core/test_testcase.py +++ b/functest/tests/unit/core/test_testcase.py @@ -28,13 +28,14 @@ class TestCaseTesting(unittest.TestCase): _case_name = "base" _project_name = "functest" + _published_result = "PASS" def setUp(self): self.test = testcase.TestCase(case_name=self._case_name, project_name=self._project_name) self.test.start_time = "1" self.test.stop_time = "2" - self.test.criteria = "PASS" + self.test.result = 100 self.test.details = {"Hello": "World"} def test_run_unimplemented(self): @@ -56,10 +57,6 @@ class TestCaseTesting(unittest.TestCase): self.test.case_name = None self._test_missing_attribute() - def test_missing_criteria(self): - self.test.criteria = None - self._test_missing_attribute() - def test_missing_start_time(self): self.test.start_time = None self._test_missing_attribute() @@ -76,7 +73,7 @@ class TestCaseTesting(unittest.TestCase): testcase.TestCase.EX_OK) mock_function.assert_called_once_with( self._project_name, self._case_name, self.test.start_time, - self.test.stop_time, self.test.criteria, self.test.details) + self.test.stop_time, self._published_result, self.test.details) @mock.patch('functest.utils.functest_utils.push_results_to_db', return_value=False) @@ -85,7 +82,7 @@ class TestCaseTesting(unittest.TestCase): testcase.TestCase.EX_PUSH_TO_DB_ERROR) mock_function.assert_called_once_with( self._project_name, self._case_name, self.test.start_time, - self.test.stop_time, self.test.criteria, self.test.details) + self.test.stop_time, self._published_result, self.test.details) @mock.patch('functest.utils.functest_utils.push_results_to_db', return_value=True) @@ -94,23 +91,77 @@ class TestCaseTesting(unittest.TestCase): testcase.TestCase.EX_OK) mock_function.assert_called_once_with( self._project_name, self._case_name, self.test.start_time, - self.test.stop_time, self.test.criteria, self.test.details) + self.test.stop_time, self._published_result, self.test.details) + + @mock.patch('functest.utils.functest_utils.push_results_to_db', + return_value=True) + def test_push_to_db_res_ko(self, mock_function=None): + self.test.result = 0 + self.assertEqual(self.test.push_to_db(), + testcase.TestCase.EX_OK) + mock_function.assert_called_once_with( + self._project_name, self._case_name, self.test.start_time, + self.test.stop_time, 'FAIL', self.test.details) + + @mock.patch('functest.utils.functest_utils.push_results_to_db', + return_value=True) + def test_push_to_db_both_ko(self, mock_function=None): + self.test.result = 0 + self.test.criteria = 0 + self.assertEqual(self.test.push_to_db(), + testcase.TestCase.EX_OK) + mock_function.assert_called_once_with( + self._project_name, self._case_name, self.test.start_time, + self.test.stop_time, 'FAIL', self.test.details) def test_check_criteria_missing(self): self.test.criteria = None - self.assertEqual(self.test.check_criteria(), + self.assertEqual(self.test.check_result(), testcase.TestCase.EX_TESTCASE_FAILED) - def test_check_criteria_failed(self): - self.test.criteria = 'FAILED' - self.assertEqual(self.test.check_criteria(), + def test_check_result_missing(self): + self.test.result = None + self.assertEqual(self.test.check_result(), testcase.TestCase.EX_TESTCASE_FAILED) - def test_check_criteria_pass(self): - self.test.criteria = 'PASS' - self.assertEqual(self.test.check_criteria(), + def test_check_result_failed(self): + # Backward compatibility + # It must be removed as soon as TestCase subclasses + # stop setting result = 'PASS' or 'FAIL'. + self.test.result = 'FAIL' + self.assertEqual(self.test.check_result(), + testcase.TestCase.EX_TESTCASE_FAILED) + + def test_check_result_pass(self): + # Backward compatibility + # It must be removed as soon as TestCase subclasses + # stop setting result = 'PASS' or 'FAIL'. + self.test.result = 'PASS' + self.assertEqual(self.test.check_result(), testcase.TestCase.EX_OK) + def test_check_result_lt(self): + self.test.result = 50 + self.assertEqual(self.test.check_result(), + testcase.TestCase.EX_TESTCASE_FAILED) + + def test_check_result_eq(self): + self.test.result = 100 + self.assertEqual(self.test.check_result(), + testcase.TestCase.EX_OK) + + def test_check_result_gt(self): + self.test.criteria = 50 + self.test.result = 100 + self.assertEqual(self.test.check_result(), + testcase.TestCase.EX_OK) + + def test_check_result_zero(self): + self.test.criteria = 0 + self.test.result = 0 + self.assertEqual(self.test.check_result(), + testcase.TestCase.EX_TESTCASE_FAILED) + if __name__ == "__main__": unittest.main(verbosity=2) diff --git a/functest/tests/unit/core/test_vnf_base.py b/functest/tests/unit/core/test_vnf_base.py index 96706040..540cf610 100644 --- a/functest/tests/unit/core/test_vnf_base.py +++ b/functest/tests/unit/core/test_vnf_base.py @@ -23,7 +23,7 @@ class VnfBaseTesting(unittest.TestCase): self.test.project = "functest" self.test.start_time = "1" self.test.stop_time = "5" - self.test.criteria = "" + self.test.result = "" self.test.details = {"orchestrator": {"status": "PASS", "result": "", "duration": 20}, diff --git a/functest/tests/unit/odl/test_odl.py b/functest/tests/unit/odl/test_odl.py index 55e100dd..80469346 100644 --- a/functest/tests/unit/odl/test_odl.py +++ b/functest/tests/unit/odl/test_odl.py @@ -123,7 +123,7 @@ class ODLParseResultTesting(ODLTesting): with mock.patch('robot.api.ExecutionResult', return_value=mock.Mock(suite=suite)): self.test.parse_results() - self.assertEqual(self.test.criteria, config['status']) + self.assertEqual(self.test.result, config['status']) self.assertEqual(self.test.start_time, timestamp_to_secs(config['starttime'])) self.assertEqual(self.test.stop_time, diff --git a/functest/tests/unit/opnfv_tests/__init__.py b/functest/tests/unit/openstack/__init__.py index e69de29b..e69de29b 100644 --- a/functest/tests/unit/opnfv_tests/__init__.py +++ b/functest/tests/unit/openstack/__init__.py diff --git a/functest/tests/unit/opnfv_tests/openstack/__init__.py b/functest/tests/unit/openstack/rally/__init__.py index e69de29b..e69de29b 100644 --- a/functest/tests/unit/opnfv_tests/openstack/__init__.py +++ b/functest/tests/unit/openstack/rally/__init__.py diff --git a/functest/tests/unit/opnfv_tests/openstack/rally/test_rally.py b/functest/tests/unit/openstack/rally/test_rally.py index fe25dfcf..fe25dfcf 100644 --- a/functest/tests/unit/opnfv_tests/openstack/rally/test_rally.py +++ b/functest/tests/unit/openstack/rally/test_rally.py diff --git a/functest/tests/unit/opnfv_tests/openstack/rally/__init__.py b/functest/tests/unit/openstack/refstack_client/__init__.py index e69de29b..e69de29b 100644 --- a/functest/tests/unit/opnfv_tests/openstack/rally/__init__.py +++ b/functest/tests/unit/openstack/refstack_client/__init__.py diff --git a/functest/tests/unit/opnfv_tests/openstack/refstack_client/test_refstack_client.py b/functest/tests/unit/openstack/refstack_client/test_refstack_client.py index 60e180c9..60e180c9 100644 --- a/functest/tests/unit/opnfv_tests/openstack/refstack_client/test_refstack_client.py +++ b/functest/tests/unit/openstack/refstack_client/test_refstack_client.py diff --git a/functest/tests/unit/opnfv_tests/openstack/refstack_client/__init__.py b/functest/tests/unit/openstack/tempest/__init__.py index e69de29b..e69de29b 100644 --- a/functest/tests/unit/opnfv_tests/openstack/refstack_client/__init__.py +++ b/functest/tests/unit/openstack/tempest/__init__.py diff --git a/functest/tests/unit/opnfv_tests/openstack/tempest/test_conf_utils.py b/functest/tests/unit/openstack/tempest/test_conf_utils.py index 8ca5cc5b..8ca5cc5b 100644 --- a/functest/tests/unit/opnfv_tests/openstack/tempest/test_conf_utils.py +++ b/functest/tests/unit/openstack/tempest/test_conf_utils.py diff --git a/functest/tests/unit/opnfv_tests/openstack/tempest/test_tempest.py b/functest/tests/unit/openstack/tempest/test_tempest.py index 34031b40..e05e5dfa 100644 --- a/functest/tests/unit/opnfv_tests/openstack/tempest/test_tempest.py +++ b/functest/tests/unit/openstack/tempest/test_tempest.py @@ -105,7 +105,7 @@ class OSTempestTesting(unittest.TestCase): self._test_generate_test_list_mode_default('full') def test_parse_verifier_result_missing_verification_uuid(self): - self.tempestcommon.VERIFICATION_ID = '' + self.tempestcommon.VERIFICATION_ID = None with self.assertRaises(Exception): self.tempestcommon.parse_verifier_result() @@ -169,100 +169,82 @@ class OSTempestTesting(unittest.TestCase): self.tempestcommon.parse_verifier_result() mock_method.assert_any_call('test_case_name', 100) - def test_run_missing_create_tempest_dir(self): - ret = testcase.TestCase.EX_RUN_ERROR - with mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.path.exists', return_value=False), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.makedirs') as mock_os_makedirs, \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.create_tempest_resources', - return_value="image_and_flavor"): - self.assertEqual(self.tempestcommon.run(), - ret) - self.assertTrue(mock_os_makedirs.called) - - def test_run_missing_configure_tempest(self): - ret = testcase.TestCase.EX_RUN_ERROR - ret_ok = testcase.TestCase.EX_OK - with mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.path.exists', return_value=False), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.makedirs') as mock_os_makedirs, \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.create_tempest_resources', - return_value=ret_ok), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.configure_tempest', - return_value=ret): - self.assertEqual(self.tempestcommon.run(), - ret) - self.assertTrue(mock_os_makedirs.called) + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'os.path.exists', return_value=False) + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.os.makedirs', + side_effect=Exception) + def test_run_makedirs_ko(self, *args): + self.assertEqual(self.tempestcommon.run(), + testcase.TestCase.EX_RUN_ERROR) + + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'os.path.exists', return_value=False) + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.os.makedirs') + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'conf_utils.create_tempest_resources', side_effect=Exception) + def test_run_create_tempest_resources_ko(self, *args): + self.assertEqual(self.tempestcommon.run(), + testcase.TestCase.EX_RUN_ERROR) + + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'os.path.exists', return_value=False) + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.os.makedirs') + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'conf_utils.create_tempest_resources', return_value={}) + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'conf_utils.configure_tempest', side_effect=Exception) + def test_run_configure_tempest_ko(self, *args): + self.assertEqual(self.tempestcommon.run(), + testcase.TestCase.EX_RUN_ERROR) + + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'os.path.exists', return_value=False) + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.os.makedirs') + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'conf_utils.create_tempest_resources', return_value={}) + @mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' + 'conf_utils.configure_tempest') + def _test_run(self, status, *args): + self.assertEqual(self.tempestcommon.run(), status) def test_run_missing_generate_test_list(self): - ret = testcase.TestCase.EX_RUN_ERROR - ret_ok = testcase.TestCase.EX_OK - with mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.path.exists', return_value=False), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.makedirs') as mock_os_makedirs, \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.create_tempest_resources', - return_value=ret_ok), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.configure_tempest', - return_value=ret_ok), \ - mock.patch.object(self.tempestcommon, 'generate_test_list', - return_value=ret): - self.assertEqual(self.tempestcommon.run(), - ret) - self.assertTrue(mock_os_makedirs.called) - - def test_run_missing_apply_tempest_blacklist(self): - ret = testcase.TestCase.EX_RUN_ERROR - ret_ok = testcase.TestCase.EX_OK - with mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.path.exists', return_value=False), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.makedirs') as mock_os_makedirs, \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.create_tempest_resources', - return_value=ret_ok), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.configure_tempest', - return_value=ret_ok), \ - mock.patch.object(self.tempestcommon, 'generate_test_list', - return_value=ret_ok), \ - mock.patch.object(self.tempestcommon, 'apply_tempest_blacklist', - return_value=ret): - self.assertEqual(self.tempestcommon.run(), - ret) - self.assertTrue(mock_os_makedirs.called) - - def test_run_missing_parse_verifier_result(self): - ret = testcase.TestCase.EX_RUN_ERROR - ret_ok = testcase.TestCase.EX_OK - with mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.path.exists', return_value=False), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'os.makedirs') as mock_os_makedirs, \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.create_tempest_resources', - return_value=ret_ok), \ - mock.patch('functest.opnfv_tests.openstack.tempest.tempest.' - 'conf_utils.configure_tempest', - return_value=ret_ok), \ - mock.patch.object(self.tempestcommon, 'generate_test_list', - return_value=ret_ok), \ - mock.patch.object(self.tempestcommon, 'apply_tempest_blacklist', - return_value=ret_ok), \ - mock.patch.object(self.tempestcommon, 'run_verifier_tests', - return_value=ret_ok), \ - mock.patch.object(self.tempestcommon, 'parse_verifier_result', - return_value=ret): - self.assertEqual(self.tempestcommon.run(), - ret) - self.assertTrue(mock_os_makedirs.called) + with mock.patch.object(self.tempestcommon, 'generate_test_list', + side_effect=Exception): + self._test_run(testcase.TestCase.EX_RUN_ERROR) + + def test_run_apply_tempest_blacklist_ko(self): + with mock.patch.object(self.tempestcommon, 'generate_test_list'), \ + mock.patch.object(self.tempestcommon, + 'apply_tempest_blacklist', + side_effect=Exception()): + self._test_run(testcase.TestCase.EX_RUN_ERROR) + + def test_run_verifier_tests_ko(self, *args): + with mock.patch.object(self.tempestcommon, 'generate_test_list'), \ + mock.patch.object(self.tempestcommon, + 'apply_tempest_blacklist'), \ + mock.patch.object(self.tempestcommon, 'run_verifier_tests', + side_effect=Exception()), \ + mock.patch.object(self.tempestcommon, 'parse_verifier_result', + side_effect=Exception): + self._test_run(testcase.TestCase.EX_RUN_ERROR) + + def test_run_parse_verifier_result_ko(self, *args): + with mock.patch.object(self.tempestcommon, 'generate_test_list'), \ + mock.patch.object(self.tempestcommon, + 'apply_tempest_blacklist'), \ + mock.patch.object(self.tempestcommon, 'run_verifier_tests'), \ + mock.patch.object(self.tempestcommon, 'parse_verifier_result', + side_effect=Exception): + self._test_run(testcase.TestCase.EX_RUN_ERROR) + + def test_run(self, *args): + with mock.patch.object(self.tempestcommon, 'generate_test_list'), \ + mock.patch.object(self.tempestcommon, + 'apply_tempest_blacklist'), \ + mock.patch.object(self.tempestcommon, 'run_verifier_tests'), \ + mock.patch.object(self.tempestcommon, 'parse_verifier_result'): + self._test_run(testcase.TestCase.EX_OK) if __name__ == "__main__": diff --git a/functest/tests/unit/opnfv_tests/vnf/__init__.py b/functest/tests/unit/opnfv_tests/vnf/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/functest/tests/unit/opnfv_tests/vnf/__init__.py +++ /dev/null diff --git a/functest/tests/unit/opnfv_tests/vnf/ims/__init__.py b/functest/tests/unit/opnfv_tests/vnf/ims/__init__.py deleted file mode 100644 index e69de29b..00000000 --- a/functest/tests/unit/opnfv_tests/vnf/ims/__init__.py +++ /dev/null diff --git a/functest/tests/unit/utils/test_functest_utils.py b/functest/tests/unit/utils/test_functest_utils.py index 22cadf0f..573fcb70 100644 --- a/functest/tests/unit/utils/test_functest_utils.py +++ b/functest/tests/unit/utils/test_functest_utils.py @@ -41,8 +41,8 @@ class FunctestUtilsTesting(unittest.TestCase): self.status = 'test_status' self.details = 'test_details' self.db_url = 'test_db_url' - self.success_rate = 2.0 - self.criteria = 'test_criteria==2.0' + self.criteria = 50 + self.result = 75 self.start_date = 1482624000 self.stop_date = 1482624000 self.start_time = time.time() @@ -279,7 +279,7 @@ class FunctestUtilsTesting(unittest.TestCase): as mock_logger_error: functest_utils.push_results_to_db(self.project, self.case_name, self.start_date, self.stop_date, - self.criteria, self.details) + self.result, self.details) mock_logger_error.assert_called_once_with("Please set env var: " + str("\'" + env_var + "\'")) @@ -311,7 +311,7 @@ class FunctestUtilsTesting(unittest.TestCase): push_results_to_db(self.project, self.case_name, self.start_date, self.stop_date, - self.criteria, self.details)) + self.result, self.details)) mock_logger_error.assert_called_once_with(test_utils. RegexMatch("Pushing " "Result to" @@ -334,7 +334,7 @@ class FunctestUtilsTesting(unittest.TestCase): push_results_to_db(self.project, self.case_name, self.start_date, self.stop_date, - self.criteria, self.details)) + self.result, self.details)) self.assertTrue(mock_logger_error.called) def test_push_results_to_db_default(self): @@ -349,7 +349,7 @@ class FunctestUtilsTesting(unittest.TestCase): push_results_to_db(self.project, self.case_name, self.start_date, self.stop_date, - self.criteria, self.details)) + self.result, self.details)) readline = 0 test_ip = ['10.1.23.4', '10.1.14.15', '10.1.16.15'] @@ -566,7 +566,7 @@ class FunctestUtilsTesting(unittest.TestCase): as mock_criteria: mock_criteria.return_value = self.criteria resp = functest_utils.check_success_rate(self.case_name, - self.success_rate) + self.result) self.assertEqual(resp, 'PASS') def test_check_success_rate_failed(self): @@ -574,7 +574,7 @@ class FunctestUtilsTesting(unittest.TestCase): as mock_criteria: mock_criteria.return_value = self.criteria resp = functest_utils.check_success_rate(self.case_name, - 3.0) + 0) self.assertEqual(resp, 'FAIL') # TODO: merge_dicts diff --git a/functest/tests/unit/opnfv_tests/openstack/tempest/__init__.py b/functest/tests/unit/vnf/ims/__init__.py index e69de29b..e69de29b 100644 --- a/functest/tests/unit/opnfv_tests/openstack/tempest/__init__.py +++ b/functest/tests/unit/vnf/ims/__init__.py diff --git a/functest/tests/unit/opnfv_tests/vnf/ims/test_clearwater.py b/functest/tests/unit/vnf/ims/test_clearwater.py index 18bebfdf..18bebfdf 100644 --- a/functest/tests/unit/opnfv_tests/vnf/ims/test_clearwater.py +++ b/functest/tests/unit/vnf/ims/test_clearwater.py diff --git a/functest/tests/unit/opnfv_tests/vnf/ims/test_cloudify_ims.py b/functest/tests/unit/vnf/ims/test_cloudify_ims.py index f47ea865..f47ea865 100644 --- a/functest/tests/unit/opnfv_tests/vnf/ims/test_cloudify_ims.py +++ b/functest/tests/unit/vnf/ims/test_cloudify_ims.py diff --git a/functest/tests/unit/opnfv_tests/vnf/ims/test_ims_base.py b/functest/tests/unit/vnf/ims/test_ims_base.py index e283199c..e283199c 100644 --- a/functest/tests/unit/opnfv_tests/vnf/ims/test_ims_base.py +++ b/functest/tests/unit/vnf/ims/test_ims_base.py diff --git a/functest/tests/unit/opnfv_tests/vnf/ims/test_orchestrator_cloudify.py b/functest/tests/unit/vnf/ims/test_orchestrator_cloudify.py index bf6d483f..bf6d483f 100644 --- a/functest/tests/unit/opnfv_tests/vnf/ims/test_orchestrator_cloudify.py +++ b/functest/tests/unit/vnf/ims/test_orchestrator_cloudify.py |