aboutsummaryrefslogtreecommitdiff
path: root/packages/Python/lldbsuite/test/functionalities/data-formatter/type_summary_list_arg/TestTypeSummaryListArg.py
blob: 6568056f761be24688669203002956245c393d0a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
"""
Test lldb data formatter subsystem.
"""

from __future__ import print_function



import os, time
import lldb
from lldbsuite.test.decorators import *
from lldbsuite.test.lldbtest import *
from lldbsuite.test import lldbutil

class TypeSummaryListArgumentTestCase(TestBase):

    mydir = TestBase.compute_mydir(__file__)

    def setUp(self):
        # Call super's setUp().
        TestBase.setUp(self)

    @no_debug_info_test
    def test_type_summary_list_with_arg(self):
        """Test that the 'type summary list' command handles command line arguments properly"""
        self.expect('type summary list Foo', substrs=['Category: default', 'Category: system'])
        self.expect('type summary list char', substrs=['char *', 'unsigned char'])

        self.expect('type summary list -w default', substrs=['system'], matching=False)
        self.expect('type summary list -w system unsigned', substrs=['default', '0-9'], matching=False)
        self.expect('type summary list -w system char', substrs=['unsigned char *'], matching=True)