1# encoding: utf-8
2"""
3Test lldb data formatter subsystem.
4"""
5
6
7import lldb
8from lldbsuite.test.decorators import *
9from lldbsuite.test.lldbtest import *
10from lldbsuite.test import lldbutil
11
12from ObjCDataFormatterTestCase import ObjCDataFormatterTestCase
13
14
15class ObjCDataFormatterNSException(ObjCDataFormatterTestCase):
16
17    def test_nsexception_with_run_command(self):
18        """Test formatters for NSException."""
19        self.appkit_tester_impl(self.nsexception_data_formatter_commands)
20
21    def nsexception_data_formatter_commands(self):
22        self.expect(
23            'frame variable except0 except1 except2 except3',
24            substrs=[
25                '(NSException *) except0 = ',
26                '@"First"',
27                '(NSException *) except1 = ',
28                '@"Second"',
29                '(NSException *) except2 = ',
30                ' @"Third"',
31                '(NSException *) except3 = ',
32                ' @"Fourth"'
33            ])
34