summaryrefslogtreecommitdiffstats
path: root/lldb/test/functionalities/command_script/TestCommandScript.py
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/test/functionalities/command_script/TestCommandScript.py')
-rw-r--r--lldb/test/functionalities/command_script/TestCommandScript.py26
1 files changed, 26 insertions, 0 deletions
diff --git a/lldb/test/functionalities/command_script/TestCommandScript.py b/lldb/test/functionalities/command_script/TestCommandScript.py
index 5064377b842..c381e4985a9 100644
--- a/lldb/test/functionalities/command_script/TestCommandScript.py
+++ b/lldb/test/functionalities/command_script/TestCommandScript.py
@@ -33,6 +33,10 @@ class CmdPythonTestCase(TestBase):
self.runCmd('command script delete welcome', check=False)
self.runCmd('command script delete targetname', check=False)
self.runCmd('command script delete longwait', check=False)
+ self.runCmd('command script delete mysto', check=False)
+ self.runCmd('command script delete tell_sync', check=False)
+ self.runCmd('command script delete tell_async', check=False)
+ self.runCmd('command script delete tell_curr', check=False)
# Execute the cleanup function during test case tear down.
self.addTearDownHook(cleanup)
@@ -83,12 +87,34 @@ class CmdPythonTestCase(TestBase):
self.expect("longwait",
substrs = ['Done; if you saw the delays I am doing OK'])
+ self.runCmd("b main")
+ self.runCmd("run")
+ self.runCmd("mysto 3")
+ self.expect("frame variable array",
+ substrs = ['[0] = 79630','[1] = 388785018','[2] = 0'])
+ self.runCmd("mysto 3")
+ self.expect("frame variable array",
+ substrs = ['[0] = 79630','[4] = 388785018','[5] = 0'])
+
+# we cannot use the stepover command to check for async execution mode since LLDB
+# seems to get confused when events start to queue up
+ self.expect("tell_sync",
+ substrs = ['running sync'])
+ self.expect("tell_async",
+ substrs = ['running async'])
+ self.expect("tell_curr",
+ substrs = ['I am running','sync'])
+
+
self.runCmd("command script clear")
self.expect('command script list', matching=False,
substrs = ['targetname',
'longwait'])
+ self.expect('command script add -f foobar frame', error=True,
+ substrs = ['cannot add command'])
+
if __name__ == '__main__':
import atexit
lldb.SBDebugger.Initialize()
OpenPOWER on IntegriCloud