Skip to content

Commit fa80a1a

Browse files
authored
[lldb][test] Move std::ranges::ref_view from libcxx to generic directory (#147705)
This just moves the test from `libcxx` to `generic`. There are currently no `std::ranges::ref_view` formatters for libstdc++ so I didn't add a test-case for it. Split out from #146740
1 parent 1e6dd8c commit fa80a1a

File tree

3 files changed

+9
-7
lines changed

3 files changed

+9
-7
lines changed

lldb/test/API/functionalities/data-formatter/data-formatter-stl/libcxx/ranges/ref_view/Makefile renamed to lldb/test/API/functionalities/data-formatter/data-formatter-stl/generic/ranges/ref_view/Makefile

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
USE_LIBCPP := 1
2-
31
CXX_SOURCES := main.cpp
42
CXXFLAGS_EXTRAS := -std=c++20
53

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
from lldbsuite.test import lldbutil
99

1010

11-
class LibcxxRangesRefViewDataFormatterTestCase(TestBase):
11+
class StdRangesRefViewDataFormatterTestCase(TestBase):
1212
def check_string_vec_children(self):
1313
return [
1414
ValueCheck(name="[0]", summary='"First"'),
@@ -27,10 +27,7 @@ def check_string_vec_ref_view(self):
2727
def check_foo(self):
2828
return ValueCheck(name="vec", children=self.check_string_vec_children())
2929

30-
@add_test_categories(["libc++"])
31-
@skipIf(compiler=no_match("clang"))
32-
@skipIf(compiler="clang", compiler_version=["<", "16.0"])
33-
def test_with_run_command(self):
30+
def do_test(self):
3431
"""Test that std::ranges::ref_view is formatted correctly when printed."""
3532
self.build()
3633
(self.target, process, thread, bkpt) = lldbutil.run_to_source_breakpoint(
@@ -69,3 +66,10 @@ def test_with_run_command(self):
6966
)
7067
],
7168
)
69+
70+
@skipIf(compiler=no_match("clang"))
71+
@skipIf(compiler="clang", compiler_version=["<", "16.0"])
72+
@add_test_categories(["libc++"])
73+
def test_libcxx(self):
74+
self.build(dictionary={"USE_LIBCPP": 1})
75+
self.do_test()

0 commit comments

Comments
 (0)