summaryrefslogtreecommitdiffstats
path: root/lldb/test/python_api
diff options
context:
space:
mode:
authorJohnny Chen <johnny.chen@apple.com>2012-01-23 19:37:53 +0000
committerJohnny Chen <johnny.chen@apple.com>2012-01-23 19:37:53 +0000
commite20e9aeb254b8cc1b55276ebae78f1f19e6c6279 (patch)
treeed68b62cb6a9f11d628d996d8a0fec8701a5eed4 /lldb/test/python_api
parent8c84d4591d76cfb4b23e8e266d58591eb1a84a74 (diff)
downloadbcm5719-llvm-e20e9aeb254b8cc1b55276ebae78f1f19e6c6279.tar.gz
bcm5719-llvm-e20e9aeb254b8cc1b55276ebae78f1f19e6c6279.zip
Dump the raw bytes and the disassembled instruction before calling self.assertTrue() instead of after,
in case the assert fails for any reason. llvm-svn: 148717
Diffstat (limited to 'lldb/test/python_api')
-rw-r--r--lldb/test/python_api/disassemble-raw-data/TestDisassembleRawData.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/lldb/test/python_api/disassemble-raw-data/TestDisassembleRawData.py b/lldb/test/python_api/disassemble-raw-data/TestDisassembleRawData.py
index fe5fdf0a3ce..44fc3c38120 100644
--- a/lldb/test/python_api/disassemble-raw-data/TestDisassembleRawData.py
+++ b/lldb/test/python_api/disassemble-raw-data/TestDisassembleRawData.py
@@ -30,14 +30,14 @@ class DisassembleRawDataTestCase(TestBase):
inst = insts.GetInstructionAtIndex(0)
- self.assertTrue (inst.GetMnemonic(target) == "movq")
- self.assertTrue (inst.GetOperands(target) == '%' + "rsp, " + '%' + "rbp")
-
if self.TraceOn():
print
print "Raw bytes: ", [hex(x) for x in raw_bytes]
print "Disassembled:", inst
+ self.assertTrue (inst.GetMnemonic(target) == "movq")
+ self.assertTrue (inst.GetOperands(target) == '%' + "rsp, " + '%' + "rbp")
+
if __name__ == '__main__':
import atexit
lldb.SBDebugger.Initialize()
OpenPOWER on IntegriCloud