aboutsummaryrefslogtreecommitdiffstats
path: root/functest/tests/unit
diff options
context:
space:
mode:
authorCedric Ollivier <cedric.ollivier@orange.com>2017-05-06 07:20:55 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-05-06 07:20:55 +0000
commit1d5e199517ff09d959a1240f3b4e715be799058b (patch)
tree453b7768851d04a64e1593691a6817f7fdc1d695 /functest/tests/unit
parent25e6056936b358d7556865deb8f3e86f63248efe (diff)
parent537b2d246673e47667866636de736a7d9bfb9884 (diff)
Merge "Rename TestCase check_result() to is_successful()"
Diffstat (limited to 'functest/tests/unit')
-rw-r--r--functest/tests/unit/core/test_testcase.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/functest/tests/unit/core/test_testcase.py b/functest/tests/unit/core/test_testcase.py
index 37948ee1..17329ea3 100644
--- a/functest/tests/unit/core/test_testcase.py
+++ b/functest/tests/unit/core/test_testcase.py
@@ -116,12 +116,12 @@ class TestCaseTesting(unittest.TestCase):
def test_check_criteria_missing(self):
self.test.criteria = None
- self.assertEqual(self.test.check_result(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_TESTCASE_FAILED)
def test_check_result_missing(self):
self.test.result = None
- self.assertEqual(self.test.check_result(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_TESTCASE_FAILED)
def test_check_result_failed(self):
@@ -129,7 +129,7 @@ class TestCaseTesting(unittest.TestCase):
# 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(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_TESTCASE_FAILED)
def test_check_result_pass(self):
@@ -137,29 +137,29 @@ class TestCaseTesting(unittest.TestCase):
# 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(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_OK)
def test_check_result_lt(self):
self.test.result = 50
- self.assertEqual(self.test.check_result(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_TESTCASE_FAILED)
def test_check_result_eq(self):
self.test.result = 100
- self.assertEqual(self.test.check_result(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_OK)
def test_check_result_gt(self):
self.test.criteria = 50
self.test.result = 100
- self.assertEqual(self.test.check_result(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_OK)
def test_check_result_zero(self):
self.test.criteria = 0
self.test.result = 0
- self.assertEqual(self.test.check_result(),
+ self.assertEqual(self.test.is_successful(),
testcase.TestCase.EX_TESTCASE_FAILED)
def test_get_duration_start_ko(self):