aboutsummaryrefslogtreecommitdiff
path: root/lldb/packages/Python/lldbsuite/test
diff options
context:
space:
mode:
authorIvan Tadeu Ferreira Antunes Filho <antunesi@google.com>2025-06-23 12:23:19 -0400
committerGitHub <noreply@github.com>2025-06-23 12:23:19 -0400
commit698e9f56558e20ceb80c08c4a880bed15970b777 (patch)
treec1bf45715d1a02b29225d90e05a9224c15b4e498 /lldb/packages/Python/lldbsuite/test
parent3dc9f2da29f7ef36ac804e20f9fb6ee1b868516e (diff)
downloadllvm-698e9f56558e20ceb80c08c4a880bed15970b777.zip
llvm-698e9f56558e20ceb80c08c4a880bed15970b777.tar.gz
llvm-698e9f56558e20ceb80c08c4a880bed15970b777.tar.bz2
[lldb] Add support for NoneType to decorator skipIfBuildType (#145342)
Currently if cmake_build_type is None we error with `AttributeError: 'NoneType' object has no attribute 'lower'` if the decorator skipIfBuildType is used. This fixes the issue by first checking that cmake_build_type is not None.
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test')
-rw-r--r--lldb/packages/Python/lldbsuite/test/decorators.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/lldb/packages/Python/lldbsuite/test/decorators.py b/lldb/packages/Python/lldbsuite/test/decorators.py
index a391319..a5f5837 100644
--- a/lldb/packages/Python/lldbsuite/test/decorators.py
+++ b/lldb/packages/Python/lldbsuite/test/decorators.py
@@ -1155,6 +1155,7 @@ def skipIfBuildType(types: list[str]):
"""
types = [name.lower() for name in types]
return unittest.skipIf(
- configuration.cmake_build_type.lower() in types,
+ configuration.cmake_build_type is not None
+ and configuration.cmake_build_type.lower() in types,
"skip on {} build type(s)".format(", ".join(types)),
)