1"""
2Test that variable expressions of integer basic types are evaluated correctly.
3"""
4
5import AbstractBase
6
7from lldbsuite.test.decorators import *
8
9
10class LongTypesExprTestCase(AbstractBase.GenericTester):
11
12    def test_long_type(self):
13        """Test that long-type variable expressions are evaluated correctly."""
14        self.build_and_run_expr('long.cpp', ['long'])
15
16    @skipUnlessDarwin
17    def test_long_type_from_block(self):
18        """Test that long-type variables are displayed correctly from a block."""
19        self.build_and_run_expr('long.cpp', ['long'], bc=True)
20
21    def test_unsigned_long_type(self):
22        """Test that 'unsigned long'-type variable expressions are evaluated correctly."""
23        self.build_and_run_expr('unsigned_long.cpp', ['unsigned', 'long'])
24
25    @skipUnlessDarwin
26    def test_unsigned_long_type_from_block(self):
27        """Test that 'unsigned_long'-type variables are displayed correctly from a block."""
28        self.build_and_run_expr(
29            'unsigned_long.cpp', ['unsigned', 'long'], bc=True)
30
31    def test_long_long_type(self):
32        """Test that 'long long'-type variable expressions are evaluated correctly."""
33        self.build_and_run_expr('long_long.cpp', ['long long'])
34
35    @skipUnlessDarwin
36    def test_long_long_type_from_block(self):
37        """Test that 'long_long'-type variables are displayed correctly from a block."""
38        self.build_and_run_expr('long_long.cpp', ['long long'], bc=True)
39
40    def test_unsigned_long_long_type(self):
41        """Test that 'unsigned long long'-type variable expressions are evaluated correctly."""
42        self.build_and_run_expr('unsigned_long_long.cpp',
43                                ['unsigned', 'long long'])
44
45    @skipUnlessDarwin
46    def test_unsigned_long_long_type_from_block(self):
47        """Test that 'unsigned_long_long'-type variables are displayed correctly from a block."""
48        self.build_and_run_expr(
49            'unsigned_long_long.cpp', ['unsigned', 'long long'], bc=True)
50