Skip to content

Commit 59e812f

Browse files
committed
[lldb][test] Skip pointer to std::unordered_map formatter tests on older Clang versions
These only work after #143501 and #144517. Skip on older compilers. This currently fails on the macOS matrix bots that run the LLDB test-suite with older Clang versions. See #146040.
1 parent f724d31 commit 59e812f

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/unordered_map-iterator/TestDataFormatterLibccUnorderedMap.py

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,21 @@ def test_iterator_formatters(self):
105105
type="const StringMapT *const &",
106106
)
107107

108-
lldbutil.continue_to_breakpoint(process, bkpt)
108+
@expectedFailureAll(
109+
bugnumber="https://github.com/llvm/llvm-project/issues/146040",
110+
compiler="clang",
111+
compiler_version=["<", "21"],
112+
)
113+
@add_test_categories(["libc++"])
114+
def test_ptr_formatters(self):
115+
"""
116+
Test that pointers to std::unordered_map are formatted correctly.
117+
"""
118+
119+
self.build()
120+
(self.target, process, thread, bkpt) = lldbutil.run_to_source_breakpoint(
121+
self, "Stop here", lldb.SBFileSpec("main.cpp", False)
122+
)
109123

110124
self.check_ptr_or_ref("ptr1")
111125
self.check_ptr_or_ref("ptr2")

lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/unordered_map-iterator/main.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ static void check_references(const StringMapT &ref1, StringMapT &ref2,
1616
static void check_pointer(const StringMapT *ptr1, StringMapT *ptr2,
1717
StringMapTPtr ptr3, StringMapTPtr *ptr4,
1818
const StringMapT *const *ptr5, StringMapT **ptr6) {
19-
std::printf("Break here");
19+
std::printf("Stop here");
2020
}
2121

2222
int main() {

0 commit comments

Comments
 (0)