[Lldb-commits] [lldb] r241436 - Make TestStopHook* remote platform compatible
Tamas Berghammer
tberghammer at google.com
Mon Jul 6 03:46:35 PDT 2015
Author: tberghammer
Date: Mon Jul 6 05:46:34 2015
New Revision: 241436
URL: http://llvm.org/viewvc/llvm-project?rev=241436&view=rev
Log:
Make TestStopHook* remote platform compatible
Modified:
lldb/trunk/test/functionalities/stop-hook/TestStopHookMechanism.py
lldb/trunk/test/functionalities/stop-hook/multiple_threads/TestStopHookMultipleThreads.py
Modified: lldb/trunk/test/functionalities/stop-hook/TestStopHookMechanism.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/functionalities/stop-hook/TestStopHookMechanism.py?rev=241436&r1=241435&r2=241436&view=diff
==============================================================================
--- lldb/trunk/test/functionalities/stop-hook/TestStopHookMechanism.py (original)
+++ lldb/trunk/test/functionalities/stop-hook/TestStopHookMechanism.py Mon Jul 6 05:46:34 2015
@@ -45,12 +45,23 @@ class StopHookMechanismTestCase(TestBase
add_prompt1 = "> "
# So that the child gets torn down after the test.
- self.child = pexpect.spawn('%s %s %s' % (lldbtest_config.lldbExec, self.lldbOption, exe))
+ self.child = pexpect.spawn('%s %s' % (lldbtest_config.lldbExec, self.lldbOption))
child = self.child
# Turn on logging for what the child sends back.
if self.TraceOn():
child.logfile_read = sys.stdout
+ if lldb.remote_platform:
+ child.expect_exact(prompt)
+ child.sendline('platform select %s' % lldb.remote_platform.GetName())
+ child.expect_exact(prompt)
+ child.sendline('platform connect %s' % lldb.platform_url)
+ child.expect_exact(prompt)
+ child.sendline('platform settings -w %s' % lldb.remote_platform_working_dir)
+
+ child.expect_exact(prompt)
+ child.sendline('target create %s' % exe)
+
# Set the breakpoint, followed by the target stop-hook commands.
child.expect_exact(prompt)
child.sendline('breakpoint set -f main.cpp -l %d' % self.begl)
Modified: lldb/trunk/test/functionalities/stop-hook/multiple_threads/TestStopHookMultipleThreads.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/functionalities/stop-hook/multiple_threads/TestStopHookMultipleThreads.py?rev=241436&r1=241435&r2=241436&view=diff
==============================================================================
--- lldb/trunk/test/functionalities/stop-hook/multiple_threads/TestStopHookMultipleThreads.py (original)
+++ lldb/trunk/test/functionalities/stop-hook/multiple_threads/TestStopHookMultipleThreads.py Mon Jul 6 05:46:34 2015
@@ -49,12 +49,23 @@ class StopHookForMultipleThreadsTestCase
prompt = "(lldb) "
# So that the child gets torn down after the test.
- self.child = pexpect.spawn('%s %s %s' % (lldbtest_config.lldbExec, self.lldbOption, exe))
+ self.child = pexpect.spawn('%s %s' % (lldbtest_config.lldbExec, self.lldbOption))
child = self.child
# Turn on logging for what the child sends back.
if self.TraceOn():
child.logfile_read = sys.stdout
+ if lldb.remote_platform:
+ child.expect_exact(prompt)
+ child.sendline('platform select %s' % lldb.remote_platform.GetName())
+ child.expect_exact(prompt)
+ child.sendline('platform connect %s' % lldb.platform_url)
+ child.expect_exact(prompt)
+ child.sendline('platform settings -w %s' % lldb.remote_platform_working_dir)
+
+ child.expect_exact(prompt)
+ child.sendline('target create %s' % exe)
+
# Set the breakpoint, followed by the target stop-hook commands.
child.expect_exact(prompt)
child.sendline('breakpoint set -f main.cpp -l %d' % self.first_stop)
More information about the lldb-commits
mailing list