• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1import lldb
2from lldbsuite.test.lldbtest import *
3from lldbsuite.test.decorators import *
4
5class InvalidArgsLogTestCase(TestBase):
6
7    mydir = TestBase.compute_mydir(__file__)
8
9    @no_debug_info_test
10    def test_enable_empty(self):
11        self.expect("log enable", error=True,
12                    substrs=["error: log enable takes a log channel and one or more log types."])
13
14    @no_debug_info_test
15    def test_disable_empty(self):
16        self.expect("log disable", error=True,
17                    substrs=["error: log disable takes a log channel and one or more log types."])
18
19    @no_debug_info_test
20    def test_enable_empty(self):
21        invalid_path = os.path.join("this", "is", "not", "a", "valid", "path")
22        self.expect("log enable lldb all -f " + invalid_path, error=True,
23                    substrs=["Unable to open log file '" + invalid_path + "': ", "\n"])
24