1""" 2Test that the user can input a format but it will not prevail over summary format's choices. 3""" 4 5 6import lldb 7from lldbsuite.test.lldbtest import * 8import lldbsuite.test.lldbutil as lldbutil 9 10 11class FrameFormatSmallStructTestCase(TestBase): 12 def setUp(self): 13 # Call super's setUp(). 14 TestBase.setUp(self) 15 # Find the line number to break at. 16 self.line = line_number("main.cpp", "// Set break point at this line.") 17 18 def test_with_run_command(self): 19 """Test that the user can input a format but it will not prevail over summary format's choices.""" 20 self.build() 21 self.runCmd("file " + self.getBuildArtifact("a.out"), CURRENT_EXECUTABLE_SET) 22 23 lldbutil.run_break_set_by_file_and_line( 24 self, "main.cpp", self.line, num_expected_locations=1, loc_exact=True 25 ) 26 27 self.runCmd("run", RUN_SUCCEEDED) 28 29 # The stop reason of the thread should be breakpoint. 30 self.expect( 31 "thread list", 32 STOPPED_DUE_TO_BREAKPOINT, 33 substrs=["stopped", "stop reason = breakpoint"], 34 ) 35 36 self.expect("thread list", substrs=["addPair(p=(x = 3, y = -3))"]) 37