[Lldb-commits] [lldb] r191378 - Cache and restore the frame-format, so that test_set_frame_format doesn't modify the default, as required for TestInferiorAssert.py.
Ashok Thirumurthi
ashok.thirumurthi at intel.com
Wed Sep 25 08:30:14 PDT 2013
Author: athirumu
Date: Wed Sep 25 10:30:14 2013
New Revision: 191378
URL: http://llvm.org/viewvc/llvm-project?rev=191378&view=rev
Log:
Cache and restore the frame-format, so that test_set_frame_format doesn't modify the default, as required for TestInferiorAssert.py.
- Also fixes this test case to set/verify a non-default frame-format and explain the intent.
Modified:
lldb/trunk/test/settings/TestSettings.py
Modified: lldb/trunk/test/settings/TestSettings.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/settings/TestSettings.py?rev=191378&r1=191377&r2=191378&view=diff
==============================================================================
--- lldb/trunk/test/settings/TestSettings.py (original)
+++ lldb/trunk/test/settings/TestSettings.py Wed Sep 25 10:30:14 2013
@@ -116,13 +116,16 @@ class SettingsCommandTestCase(TestBase):
self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET)
def cleanup():
- format_string = "frame #${frame.index}: ${frame.pc}{ ${module.file.basename}{`${function.name}${function.pc-offset}}}{ at ${line.file.basename}:${line.number}}\n"
- self.runCmd("settings set frame-format %s" % format_string, check=False)
+ self.runCmd("settings set frame-format %s" % self.format_string, check=False)
# Execute the cleanup function during test case tear down.
self.addTearDownHook(cleanup)
- format_string = "frame #${frame.index}: ${frame.pc}{ ${module.file.basename}`${function.name-with-args}{${function.pc-offset}}}{ at ${line.file.fullpath}:${line.number}}\n"
+ self.runCmd("settings show frame-format")
+ self.format_string = self.res.GetOutput()
+
+ # Change the default format to print function.name rather than function.name-with-args
+ format_string = "frame #${frame.index}: ${frame.pc}{ ${module.file.basename}`${function.name}{${function.pc-offset}}}{ at ${line.file.fullpath}:${line.number}}\n"
self.runCmd("settings set frame-format %s" % format_string)
# Immediately test the setting.
More information about the lldb-commits
mailing list