From dc8b2d3d3aa4cedd66ee5b113ee8cc535f2c5a04 Mon Sep 17 00:00:00 2001 From: Pavel Labath Date: Mon, 26 Oct 2015 09:28:32 +0000 Subject: Port the python api decorator to use test categories Summary: Per discussions on the mailing list, I have implemented a decorator which annotates individual test methods with categories. I have used this framework to replace the '-a' and '+a' command-line switches (now '-G pyapi' and '--skip-category pyapi') and the @python_api_test decorator (now @add_test_categories('pyapi')). The test suite now gives an error message suggesting the new options if the user specifies the deprecated +/-a switches. If the general direction is good, I will follow this up with other switches. Reviewers: tberghammer, tfiala, granata.enrico, zturner Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D14020 llvm-svn: 251277 --- lldb/test/python_api/module_section/TestModuleAndSection.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lldb/test/python_api/module_section') diff --git a/lldb/test/python_api/module_section/TestModuleAndSection.py b/lldb/test/python_api/module_section/TestModuleAndSection.py index c89ff221d62..d12f1ae6ba3 100644 --- a/lldb/test/python_api/module_section/TestModuleAndSection.py +++ b/lldb/test/python_api/module_section/TestModuleAndSection.py @@ -16,7 +16,7 @@ class ModuleAndSectionAPIsTestCase(TestBase): mydir = TestBase.compute_mydir(__file__) - @python_api_test + @add_test_categories(['pyapi']) def test_module_and_section(self): """Test module and section APIs.""" self.build() @@ -56,7 +56,7 @@ class ModuleAndSectionAPIsTestCase(TestBase): print(INDENT2 + str(sym)) print(INDENT2 + "symbol type: %s" % symbol_type_to_str(sym.GetType())) - @python_api_test + @add_test_categories(['pyapi']) def test_module_and_section_boundary_condition(self): """Test module and section APIs by passing None when it expects a Python string.""" self.build() @@ -97,7 +97,7 @@ class ModuleAndSectionAPIsTestCase(TestBase): if sec1: sec1.FindSubSection(None) - @python_api_test + @add_test_categories(['pyapi']) def test_module_compile_unit_iter(self): """Test module's compile unit iterator APIs.""" self.build() -- cgit v1.2.3