80b144f58d5732cc9fdbf2d9c947295237e2be47
[openbsd] /
1 """
2 Test multiword commands ('platform' in this case).
3 """
4
5 import lldb
6 from lldbsuite.test.decorators import *
7 from lldbsuite.test.lldbtest import *
8
9 class MultiwordCommandsTestCase(TestBase):
10
11     mydir = TestBase.compute_mydir(__file__)
12
13     @no_debug_info_test
14     def test_ambiguous_subcommand(self):
15         self.expect("platform s", error=True,
16                     substrs=["ambiguous command 'platform s'. Possible completions:",
17                              "\tselect\n",
18                              "\tshell\n",
19                              "\tsettings\n"])
20
21     @no_debug_info_test
22     def test_empty_subcommand(self):
23         self.expect("platform \"\"", error=True, substrs=["Need to specify a non-empty subcommand."])
24
25     @no_debug_info_test
26     def test_help(self):
27         # <multiword> help brings up help.
28         self.expect("platform help",
29                     substrs=["Commands to manage and create platforms.",
30                              "Syntax: platform [",
31                              "The following subcommands are supported:",
32                              "connect",
33                              "Select the current platform"])