[lldb] Standardize TestVectorOfEnums.py as a C++ data formatter test (#189757)
This is explicitly marked as a libc++ test and functionally tests the formatter for a vector of enums. I put it in the generic directory because there's no reason this couldn't work for other c++ stdlibs. Additionally, this should be using the custom libc++ like the other tests.
This commit is contained in:
parent
d0e265f20d
commit
343210656c
@ -3,7 +3,6 @@ Test Expression Parser regression test to ensure that we handle enums
|
||||
correctly, in this case specifically std::vector of enums.
|
||||
"""
|
||||
|
||||
|
||||
import lldb
|
||||
from lldbsuite.test.decorators import *
|
||||
from lldbsuite.test.lldbtest import *
|
||||
@ -11,9 +10,11 @@ from lldbsuite.test import lldbutil
|
||||
|
||||
|
||||
class TestVectorOfEnums(TestBase):
|
||||
SHARED_BUILD_TESTCASE = False
|
||||
|
||||
@add_test_categories(["libc++"])
|
||||
def test_vector_of_enums(self):
|
||||
self.build()
|
||||
self.build(dictionary={"USE_LIBCPP": 1})
|
||||
|
||||
lldbutil.run_to_source_breakpoint(
|
||||
self, "// break here", lldb.SBFileSpec("main.cpp", False)
|
||||
@ -1,11 +1,6 @@
|
||||
#include <vector>
|
||||
|
||||
enum E {
|
||||
a,
|
||||
b,
|
||||
c,
|
||||
d
|
||||
} ;
|
||||
enum E { a, b, c, d };
|
||||
|
||||
int main() {
|
||||
std::vector<E> v = {E::a, E::b, E::c};
|
||||
Loading…
x
Reference in New Issue
Block a user