From 648d31af02248b8b2da059e228c10f1e3f81eb5b Mon Sep 17 00:00:00 2001 From: Cédric Ollivier Date: Thu, 11 May 2017 10:03:47 +0200 Subject: Modify TestCase.__str__() to use PrettyTable MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It adds PrettyTable as requirement even if it's already defined in OpenStack client dependencies. If the TestCase object is considered as invalid, it simply returns the default str. Change-Id: Iee788aef2a13694d9482560977cbbf21c7f2c967 Signed-off-by: Cédric Ollivier --- functest/tests/unit/core/test_testcase.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'functest/tests') diff --git a/functest/tests/unit/core/test_testcase.py b/functest/tests/unit/core/test_testcase.py index b25ce226..08a717a2 100644 --- a/functest/tests/unit/core/test_testcase.py +++ b/functest/tests/unit/core/test_testcase.py @@ -191,11 +191,13 @@ class TestCaseTesting(unittest.TestCase): def test_str_project_name_ko(self): self.test.project_name = None - self.assertIn("INVALID OBJECT", str(self.test)) + self.assertIn("