[Lldb-commits] [PATCH] D83600: Add a decorator to skip tests when running under Rosetta
Adrian Prantl via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Mon Jul 13 13:11:37 PDT 2020
This revision was automatically updated to reflect the committed changes.
Closed by commit rG341ec5641821: Add a decorator to skip tests when running under Rosetta (authored by aprantl).
Herald added a project: LLDB.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D83600/new/
https://reviews.llvm.org/D83600
Files:
lldb/packages/Python/lldbsuite/test/decorators.py
Index: lldb/packages/Python/lldbsuite/test/decorators.py
===================================================================
--- lldb/packages/Python/lldbsuite/test/decorators.py
+++ lldb/packages/Python/lldbsuite/test/decorators.py
@@ -552,6 +552,14 @@
return skipTestIfFn(are_sb_headers_missing)(func)
+def skipIfRosetta(func, bugnumber=None):
+ """Skip a test when running the testsuite on macOS under the Rosetta translation layer."""
+ def is_running_rosetta(self):
+ if not lldbplatformutil.getPlatform() in ['darwin', 'macosx']:
+ return False
+ return platform.uname()[5] == "arm" and self.getArchitecture() == "x86_64"
+ return skipTestIfFn(is_running_rosetta, bugnumber)(func)
+
def skipIfiOSSimulator(func):
"""Decorate the item to skip tests that should be skipped on the iOS Simulator."""
def is_ios_simulator():
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D83600.277545.patch
Type: text/x-patch
Size: 880 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20200713/6231d465/attachment.bin>
More information about the lldb-commits
mailing list