diff options
author | Cédric Ollivier <cedric.ollivier@orange.com> | 2017-03-27 10:26:05 +0200 |
---|---|---|
committer | Cédric Ollivier <cedric.ollivier@orange.com> | 2017-03-27 10:36:11 +0200 |
commit | 69e51470d8e9f51e02d5f0bd6e957c4e24c603c6 (patch) | |
tree | 18a3fdc6b9f1e4716833b5ee74c65fabf2083a4c /functest/tests/unit/core | |
parent | 407d27585f109e3381bb49041abc49a14b7b5bfe (diff) |
Rename testcase_base to testcase
It simply removes the useless suffix.
Change-Id: Ib9a682b57d8f33518359d817a593bb3786577390
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
Diffstat (limited to 'functest/tests/unit/core')
-rw-r--r-- | functest/tests/unit/core/test_testcase_base.py | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/functest/tests/unit/core/test_testcase_base.py b/functest/tests/unit/core/test_testcase_base.py index a98caead..9ee1609f 100644 --- a/functest/tests/unit/core/test_testcase_base.py +++ b/functest/tests/unit/core/test_testcase_base.py @@ -12,7 +12,7 @@ import unittest import mock -from functest.core import testcase_base +from functest.core import testcase class TestCaseTesting(unittest.TestCase): @@ -20,7 +20,7 @@ class TestCaseTesting(unittest.TestCase): logging.disable(logging.CRITICAL) def setUp(self): - self.test = testcase_base.TestCase() + self.test = testcase.TestCase() self.test.project = "functest" self.test.case_name = "base" self.test.start_time = "1" @@ -30,13 +30,13 @@ class TestCaseTesting(unittest.TestCase): def test_run_unimplemented(self): self.assertEqual(self.test.run(), - testcase_base.TestCase.EX_RUN_ERROR) + testcase.TestCase.EX_RUN_ERROR) @mock.patch('functest.utils.functest_utils.push_results_to_db', return_value=False) def _test_missing_attribute(self, mock_function=None): self.assertEqual(self.test.push_to_db(), - testcase_base.TestCase.EX_PUSH_TO_DB_ERROR) + testcase.TestCase.EX_PUSH_TO_DB_ERROR) mock_function.assert_not_called() def test_missing_case_name(self): @@ -60,7 +60,7 @@ class TestCaseTesting(unittest.TestCase): def test_missing_details(self, mock_function=None): self.test.details = None self.assertEqual(self.test.push_to_db(), - testcase_base.TestCase.EX_OK) + testcase.TestCase.EX_OK) mock_function.assert_called_once_with( self.test.project, self.test.case_name, self.test.start_time, self.test.stop_time, self.test.criteria, self.test.details) @@ -69,7 +69,7 @@ class TestCaseTesting(unittest.TestCase): return_value=False) def test_push_to_db_failed(self, mock_function=None): self.assertEqual(self.test.push_to_db(), - testcase_base.TestCase.EX_PUSH_TO_DB_ERROR) + testcase.TestCase.EX_PUSH_TO_DB_ERROR) mock_function.assert_called_once_with( self.test.project, self.test.case_name, self.test.start_time, self.test.stop_time, self.test.criteria, self.test.details) @@ -78,7 +78,7 @@ class TestCaseTesting(unittest.TestCase): return_value=True) def test_push_to_db(self, mock_function=None): self.assertEqual(self.test.push_to_db(), - testcase_base.TestCase.EX_OK) + testcase.TestCase.EX_OK) mock_function.assert_called_once_with( self.test.project, self.test.case_name, self.test.start_time, self.test.stop_time, self.test.criteria, self.test.details) @@ -86,17 +86,17 @@ class TestCaseTesting(unittest.TestCase): def test_check_criteria_missing(self): self.test.criteria = None self.assertEqual(self.test.check_criteria(), - testcase_base.TestCase.EX_TESTCASE_FAILED) + testcase.TestCase.EX_TESTCASE_FAILED) def test_check_criteria_failed(self): self.test.criteria = 'FAILED' self.assertEqual(self.test.check_criteria(), - testcase_base.TestCase.EX_TESTCASE_FAILED) + testcase.TestCase.EX_TESTCASE_FAILED) def test_check_criteria_pass(self): self.test.criteria = 'PASS' self.assertEqual(self.test.check_criteria(), - testcase_base.TestCase.EX_OK) + testcase.TestCase.EX_OK) if __name__ == "__main__": |