Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / lldb / test / API / lang / cpp / frame-var-depth-and-elem-count / TestFrameVarDepthAndElemCount.py
blob1dfd7df9ff1be8a90b8c43e7ed9c45252beea277
1 """
2 Tests that frame variable --depth and --element-count options work correctly
3 together
4 """
5 import lldb
6 from lldbsuite.test.lldbtest import *
7 import lldbsuite.test.lldbutil as lldbutil
10 class TestFrameVarDepthAndElemCount(TestBase):
11 def test(self):
12 """Test that bool types work in the expression parser"""
13 self.build()
14 lldbutil.run_to_source_breakpoint(
15 self, "break here", lldb.SBFileSpec("main.cpp")
18 # Check that we print 5 elements but only 2 levels deep.
19 self.expect(
20 "frame var --depth 2 --element-count 5 -- c",
21 substrs=[
22 "[0] = {\n b ={...}\n }",
23 "[1] = {\n b ={...}\n }",
24 "[2] = {\n b ={...}\n }",
25 "[3] = {\n b ={...}\n }",
26 "[4] = {\n b ={...}\n }",