[Lldb-commits] [lldb] f5759d5 - [Test] Split up TestIntegerTypes.py

Jonas Devlieghere via lldb-commits lldb-commits at lists.llvm.org
Thu Nov 21 11:24:23 PST 2019


Author: Jonas Devlieghere
Date: 2019-11-21T11:24:14-08:00
New Revision: f5759d5dbc441f1fe956757408f46e65611b94e5

URL: https://github.com/llvm/llvm-project/commit/f5759d5dbc441f1fe956757408f46e65611b94e5
DIFF: https://github.com/llvm/llvm-project/commit/f5759d5dbc441f1fe956757408f46e65611b94e5.diff

LOG: [Test] Split up TestIntegerTypes.py

The unsplit test is timing out on GreenDragon's sanitized bot. By
splitting the test we avoid this issue and increase parallelism.

Added: 
    lldb/packages/Python/lldbsuite/test/types/TestCharType.py
    lldb/packages/Python/lldbsuite/test/types/TestCharTypeExpr.py
    lldb/packages/Python/lldbsuite/test/types/TestIntegerType.py
    lldb/packages/Python/lldbsuite/test/types/TestIntegerTypeExpr.py
    lldb/packages/Python/lldbsuite/test/types/TestLongTypes.py
    lldb/packages/Python/lldbsuite/test/types/TestLongTypesExpr.py
    lldb/packages/Python/lldbsuite/test/types/TestShortType.py
    lldb/packages/Python/lldbsuite/test/types/TestShortTypeExpr.py

Modified: 
    

Removed: 
    lldb/packages/Python/lldbsuite/test/types/TestIntegerTypes.py
    lldb/packages/Python/lldbsuite/test/types/TestIntegerTypesExpr.py


################################################################################
diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestCharType.py b/lldb/packages/Python/lldbsuite/test/types/TestCharType.py
new file mode 100644
index 000000000000..bc568702c669
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestCharType.py
@@ -0,0 +1,32 @@
+"""
+Test that variables of type char are displayed correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class CharTypeTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    def test_char_type(self):
+        """Test that char-type variables are displayed correctly."""
+        self.build_and_run('char.cpp', set(['char']), qd=True)
+
+    @skipUnlessDarwin
+    def test_char_type_from_block(self):
+        """Test that char-type variables are displayed correctly from a block."""
+        self.build_and_run('char.cpp', set(['char']), bc=True, qd=True)
+
+    def test_unsigned_char_type(self):
+        """Test that 'unsigned_char'-type variables are displayed correctly."""
+        self.build_and_run(
+            'unsigned_char.cpp', set(['unsigned', 'char']), qd=True)
+
+    @skipUnlessDarwin
+    def test_unsigned_char_type_from_block(self):
+        """Test that 'unsigned char'-type variables are displayed correctly from a block."""
+        self.build_and_run(
+            'unsigned_char.cpp', set(['unsigned', 'char']), bc=True, qd=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestCharTypeExpr.py b/lldb/packages/Python/lldbsuite/test/types/TestCharTypeExpr.py
new file mode 100644
index 000000000000..63ddc1451b95
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestCharTypeExpr.py
@@ -0,0 +1,32 @@
+"""
+Test that variable expressions of type char are evaluated correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class CharTypeExprTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    def test_char_type(self):
+        """Test that char-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('char.cpp', set(['char']), qd=True)
+
+    @skipUnlessDarwin
+    def test_char_type_from_block(self):
+        """Test that char-type variables are displayed correctly from a block."""
+        self.build_and_run_expr('char.cpp', set(['char']), bc=True, qd=True)
+
+    def test_unsigned_char_type(self):
+        """Test that 'unsigned_char'-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr(
+            'unsigned_char.cpp', set(['unsigned', 'char']), qd=True)
+
+    @skipUnlessDarwin
+    def test_unsigned_char_type_from_block(self):
+        """Test that 'unsigned char'-type variables are displayed correctly from a block."""
+        self.build_and_run_expr(
+            'unsigned_char.cpp', set(['unsigned', 'char']), bc=True, qd=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestIntegerType.py b/lldb/packages/Python/lldbsuite/test/types/TestIntegerType.py
new file mode 100644
index 000000000000..549b37af3e8c
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestIntegerType.py
@@ -0,0 +1,31 @@
+"""
+Test that variables of type integer are displayed correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class IntegerTypesTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    def test_int_type(self):
+        """Test that int-type variables are displayed correctly."""
+        self.build_and_run('int.cpp', set(['int']))
+
+    @skipUnlessDarwin
+    def test_int_type_from_block(self):
+        """Test that int-type variables are displayed correctly from a block."""
+        self.build_and_run('int.cpp', set(['int']))
+
+    def test_unsigned_int_type(self):
+        """Test that 'unsigned_int'-type variables are displayed correctly."""
+        self.build_and_run('unsigned_int.cpp', set(['unsigned', 'int']))
+
+    @skipUnlessDarwin
+    def test_unsigned_int_type_from_block(self):
+        """Test that 'unsigned int'-type variables are displayed correctly from a block."""
+        self.build_and_run(
+            'unsigned_int.cpp', set(['unsigned', 'int']), bc=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypeExpr.py b/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypeExpr.py
new file mode 100644
index 000000000000..0b258dbaa67f
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypeExpr.py
@@ -0,0 +1,37 @@
+"""
+Test that variable expressions of type integer are evaluated correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class IntegerTypeExprTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    @skipUnlessDarwin
+    def test_unsigned_short_type_from_block(self):
+        """Test that 'unsigned short'-type variables are displayed correctly from a block."""
+        self.build_and_run_expr(
+            'unsigned_short.cpp', set(['unsigned', 'short']), bc=True)
+
+    def test_int_type(self):
+        """Test that int-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('int.cpp', set(['int']))
+
+    @skipUnlessDarwin
+    def test_int_type_from_block(self):
+        """Test that int-type variables are displayed correctly from a block."""
+        self.build_and_run_expr('int.cpp', set(['int']))
+
+    def test_unsigned_int_type(self):
+        """Test that 'unsigned_int'-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('unsigned_int.cpp', set(['unsigned', 'int']))
+
+    @skipUnlessDarwin
+    def test_unsigned_int_type_from_block(self):
+        """Test that 'unsigned int'-type variables are displayed correctly from a block."""
+        self.build_and_run_expr(
+            'unsigned_int.cpp', set(['unsigned', 'int']), bc=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypes.py b/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypes.py
deleted file mode 100644
index c73ea421efd6..000000000000
--- a/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypes.py
+++ /dev/null
@@ -1,108 +0,0 @@
-"""
-Test that variables of integer basic types are displayed correctly.
-"""
-
-import AbstractBase
-
-from lldbsuite.test.decorators import *
-
-class IntegerTypesTestCase(AbstractBase.GenericTester):
-
-    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
-
-    def test_char_type(self):
-        """Test that char-type variables are displayed correctly."""
-        self.build_and_run('char.cpp', set(['char']), qd=True)
-
-    @skipUnlessDarwin
-    def test_char_type_from_block(self):
-        """Test that char-type variables are displayed correctly from a block."""
-        self.build_and_run('char.cpp', set(['char']), bc=True, qd=True)
-
-    def test_unsigned_char_type(self):
-        """Test that 'unsigned_char'-type variables are displayed correctly."""
-        self.build_and_run('unsigned_char.cpp', set(
-            ['unsigned', 'char']), qd=True)
-
-    @skipUnlessDarwin
-    def test_unsigned_char_type_from_block(self):
-        """Test that 'unsigned char'-type variables are displayed correctly from a block."""
-        self.build_and_run('unsigned_char.cpp', set(
-            ['unsigned', 'char']), bc=True, qd=True)
-
-    def test_short_type(self):
-        """Test that short-type variables are displayed correctly."""
-        self.build_and_run('short.cpp', set(['short']))
-
-    @skipUnlessDarwin
-    def test_short_type_from_block(self):
-        """Test that short-type variables are displayed correctly from a block."""
-        self.build_and_run('short.cpp', set(['short']), bc=True)
-
-    def test_unsigned_short_type(self):
-        """Test that 'unsigned_short'-type variables are displayed correctly."""
-        self.build_and_run('unsigned_short.cpp', set(['unsigned', 'short']))
-
-    @skipUnlessDarwin
-    def test_unsigned_short_type_from_block(self):
-        """Test that 'unsigned short'-type variables are displayed correctly from a block."""
-        self.build_and_run('unsigned_short.cpp', set(
-            ['unsigned', 'short']), bc=True)
-
-    def test_int_type(self):
-        """Test that int-type variables are displayed correctly."""
-        self.build_and_run('int.cpp', set(['int']))
-
-    @skipUnlessDarwin
-    def test_int_type_from_block(self):
-        """Test that int-type variables are displayed correctly from a block."""
-        self.build_and_run('int.cpp', set(['int']))
-
-    def test_unsigned_int_type(self):
-        """Test that 'unsigned_int'-type variables are displayed correctly."""
-        self.build_and_run('unsigned_int.cpp', set(['unsigned', 'int']))
-
-    @skipUnlessDarwin
-    def test_unsigned_int_type_from_block(self):
-        """Test that 'unsigned int'-type variables are displayed correctly from a block."""
-        self.build_and_run('unsigned_int.cpp', set(
-            ['unsigned', 'int']), bc=True)
-
-    def test_long_type(self):
-        """Test that long-type variables are displayed correctly."""
-        self.build_and_run('long.cpp', set(['long']))
-
-    @skipUnlessDarwin
-    def test_long_type_from_block(self):
-        """Test that long-type variables are displayed correctly from a block."""
-        self.build_and_run('long.cpp', set(['long']), bc=True)
-
-    def test_unsigned_long_type(self):
-        """Test that 'unsigned long'-type variables are displayed correctly."""
-        self.build_and_run('unsigned_long.cpp', set(['unsigned', 'long']))
-
-    @skipUnlessDarwin
-    def test_unsigned_long_type_from_block(self):
-        """Test that 'unsigned_long'-type variables are displayed correctly from a block."""
-        self.build_and_run('unsigned_long.cpp', set(
-            ['unsigned', 'long']), bc=True)
-
-    def test_long_long_type(self):
-        """Test that 'long long'-type variables are displayed correctly."""
-        self.build_and_run('long_long.cpp', set(['long long']))
-
-    @skipUnlessDarwin
-    def test_long_long_type_from_block(self):
-        """Test that 'long_long'-type variables are displayed correctly from a block."""
-        self.build_and_run('long_long.cpp', set(['long long']), bc=True)
-
-    def test_unsigned_long_long_type(self):
-        """Test that 'unsigned long long'-type variables are displayed correctly."""
-        self.build_and_run('unsigned_long_long.cpp',
-                           set(['unsigned', 'long long']))
-
-    @skipUnlessDarwin
-    def test_unsigned_long_long_type_from_block(self):
-        """Test that 'unsigned_long_long'-type variables are displayed correctly from a block."""
-        self.build_and_run('unsigned_long_long.cpp', set(
-            ['unsigned', 'long long']), bc=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypesExpr.py b/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypesExpr.py
deleted file mode 100644
index 8b603e85a7b9..000000000000
--- a/lldb/packages/Python/lldbsuite/test/types/TestIntegerTypesExpr.py
+++ /dev/null
@@ -1,109 +0,0 @@
-"""
-Test that variable expressions of integer basic types are evaluated correctly.
-"""
-
-import AbstractBase
-
-from lldbsuite.test.decorators import *
-
-class IntegerTypesExprTestCase(AbstractBase.GenericTester):
-
-    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
-
-    def test_char_type(self):
-        """Test that char-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('char.cpp', set(['char']), qd=True)
-
-    @skipUnlessDarwin
-    def test_char_type_from_block(self):
-        """Test that char-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('char.cpp', set(['char']), bc=True, qd=True)
-
-    def test_unsigned_char_type(self):
-        """Test that 'unsigned_char'-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('unsigned_char.cpp', set(
-            ['unsigned', 'char']), qd=True)
-
-    @skipUnlessDarwin
-    def test_unsigned_char_type_from_block(self):
-        """Test that 'unsigned char'-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('unsigned_char.cpp', set(
-            ['unsigned', 'char']), bc=True, qd=True)
-
-    def test_short_type(self):
-        """Test that short-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('short.cpp', set(['short']))
-
-    @skipUnlessDarwin
-    def test_short_type_from_block(self):
-        """Test that short-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('short.cpp', set(['short']), bc=True)
-
-    def test_unsigned_short_type(self):
-        """Test that 'unsigned_short'-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('unsigned_short.cpp',
-                                set(['unsigned', 'short']))
-
-    @skipUnlessDarwin
-    def test_unsigned_short_type_from_block(self):
-        """Test that 'unsigned short'-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('unsigned_short.cpp', set(
-            ['unsigned', 'short']), bc=True)
-
-    def test_int_type(self):
-        """Test that int-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('int.cpp', set(['int']))
-
-    @skipUnlessDarwin
-    def test_int_type_from_block(self):
-        """Test that int-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('int.cpp', set(['int']))
-
-    def test_unsigned_int_type(self):
-        """Test that 'unsigned_int'-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('unsigned_int.cpp', set(['unsigned', 'int']))
-
-    @skipUnlessDarwin
-    def test_unsigned_int_type_from_block(self):
-        """Test that 'unsigned int'-type variables are displayed correctly from a block."""
-        self.build_and_run_expr(
-            'unsigned_int.cpp', set(['unsigned', 'int']), bc=True)
-
-    def test_long_type(self):
-        """Test that long-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('long.cpp', set(['long']))
-
-    @skipUnlessDarwin
-    def test_long_type_from_block(self):
-        """Test that long-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('long.cpp', set(['long']), bc=True)
-
-    def test_unsigned_long_type(self):
-        """Test that 'unsigned long'-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('unsigned_long.cpp', set(['unsigned', 'long']))
-
-    @skipUnlessDarwin
-    def test_unsigned_long_type_from_block(self):
-        """Test that 'unsigned_long'-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('unsigned_long.cpp', set(
-            ['unsigned', 'long']), bc=True)
-
-    def test_long_long_type(self):
-        """Test that 'long long'-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('long_long.cpp', set(['long long']))
-
-    @skipUnlessDarwin
-    def test_long_long_type_from_block(self):
-        """Test that 'long_long'-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('long_long.cpp', set(['long long']), bc=True)
-
-    def test_unsigned_long_long_type(self):
-        """Test that 'unsigned long long'-type variable expressions are evaluated correctly."""
-        self.build_and_run_expr('unsigned_long_long.cpp',
-                                set(['unsigned', 'long long']))
-
-    @skipUnlessDarwin
-    def test_unsigned_long_long_type_from_block(self):
-        """Test that 'unsigned_long_long'-type variables are displayed correctly from a block."""
-        self.build_and_run_expr('unsigned_long_long.cpp', set(
-            ['unsigned', 'long long']), bc=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestLongTypes.py b/lldb/packages/Python/lldbsuite/test/types/TestLongTypes.py
new file mode 100644
index 000000000000..28f81937409e
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestLongTypes.py
@@ -0,0 +1,51 @@
+"""
+Test that variables of integer basic types are displayed correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class LongTypesTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    def test_long_type(self):
+        """Test that long-type variables are displayed correctly."""
+        self.build_and_run('long.cpp', set(['long']))
+
+    @skipUnlessDarwin
+    def test_long_type_from_block(self):
+        """Test that long-type variables are displayed correctly from a block."""
+        self.build_and_run('long.cpp', set(['long']), bc=True)
+
+    def test_unsigned_long_type(self):
+        """Test that 'unsigned long'-type variables are displayed correctly."""
+        self.build_and_run('unsigned_long.cpp', set(['unsigned', 'long']))
+
+    @skipUnlessDarwin
+    def test_unsigned_long_type_from_block(self):
+        """Test that 'unsigned_long'-type variables are displayed correctly from a block."""
+        self.build_and_run(
+            'unsigned_long.cpp', set(['unsigned', 'long']), bc=True)
+
+    def test_long_long_type(self):
+        """Test that 'long long'-type variables are displayed correctly."""
+        self.build_and_run('long_long.cpp', set(['long long']))
+
+    @skipUnlessDarwin
+    def test_long_long_type_from_block(self):
+        """Test that 'long_long'-type variables are displayed correctly from a block."""
+        self.build_and_run('long_long.cpp', set(['long long']), bc=True)
+
+    def test_unsigned_long_long_type(self):
+        """Test that 'unsigned long long'-type variables are displayed correctly."""
+        self.build_and_run('unsigned_long_long.cpp',
+                           set(['unsigned', 'long long']))
+
+    @skipUnlessDarwin
+    def test_unsigned_long_long_type_from_block(self):
+        """Test that 'unsigned_long_long'-type variables are displayed correctly from a block."""
+        self.build_and_run(
+            'unsigned_long_long.cpp', set(['unsigned', 'long long']), bc=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestLongTypesExpr.py b/lldb/packages/Python/lldbsuite/test/types/TestLongTypesExpr.py
new file mode 100644
index 000000000000..b753a9d5a890
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestLongTypesExpr.py
@@ -0,0 +1,51 @@
+"""
+Test that variable expressions of integer basic types are evaluated correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class LongTypesExprTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    def test_long_type(self):
+        """Test that long-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('long.cpp', set(['long']))
+
+    @skipUnlessDarwin
+    def test_long_type_from_block(self):
+        """Test that long-type variables are displayed correctly from a block."""
+        self.build_and_run_expr('long.cpp', set(['long']), bc=True)
+
+    def test_unsigned_long_type(self):
+        """Test that 'unsigned long'-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('unsigned_long.cpp', set(['unsigned', 'long']))
+
+    @skipUnlessDarwin
+    def test_unsigned_long_type_from_block(self):
+        """Test that 'unsigned_long'-type variables are displayed correctly from a block."""
+        self.build_and_run_expr(
+            'unsigned_long.cpp', set(['unsigned', 'long']), bc=True)
+
+    def test_long_long_type(self):
+        """Test that 'long long'-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('long_long.cpp', set(['long long']))
+
+    @skipUnlessDarwin
+    def test_long_long_type_from_block(self):
+        """Test that 'long_long'-type variables are displayed correctly from a block."""
+        self.build_and_run_expr('long_long.cpp', set(['long long']), bc=True)
+
+    def test_unsigned_long_long_type(self):
+        """Test that 'unsigned long long'-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('unsigned_long_long.cpp',
+                                set(['unsigned', 'long long']))
+
+    @skipUnlessDarwin
+    def test_unsigned_long_long_type_from_block(self):
+        """Test that 'unsigned_long_long'-type variables are displayed correctly from a block."""
+        self.build_and_run_expr(
+            'unsigned_long_long.cpp', set(['unsigned', 'long long']), bc=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestShortType.py b/lldb/packages/Python/lldbsuite/test/types/TestShortType.py
new file mode 100644
index 000000000000..d940d1ba0176
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestShortType.py
@@ -0,0 +1,31 @@
+"""
+Test that variables of type short are displayed correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class ShortTypeTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    def test_short_type(self):
+        """Test that short-type variables are displayed correctly."""
+        self.build_and_run('short.cpp', set(['short']))
+
+    @skipUnlessDarwin
+    def test_short_type_from_block(self):
+        """Test that short-type variables are displayed correctly from a block."""
+        self.build_and_run('short.cpp', set(['short']), bc=True)
+
+    def test_unsigned_short_type(self):
+        """Test that 'unsigned_short'-type variables are displayed correctly."""
+        self.build_and_run('unsigned_short.cpp', set(['unsigned', 'short']))
+
+    @skipUnlessDarwin
+    def test_unsigned_short_type_from_block(self):
+        """Test that 'unsigned short'-type variables are displayed correctly from a block."""
+        self.build_and_run(
+            'unsigned_short.cpp', set(['unsigned', 'short']), bc=True)

diff  --git a/lldb/packages/Python/lldbsuite/test/types/TestShortTypeExpr.py b/lldb/packages/Python/lldbsuite/test/types/TestShortTypeExpr.py
new file mode 100644
index 000000000000..17bcfd378e10
--- /dev/null
+++ b/lldb/packages/Python/lldbsuite/test/types/TestShortTypeExpr.py
@@ -0,0 +1,32 @@
+"""
+Test that variable expressions of type short are evaluated correctly.
+"""
+
+import AbstractBase
+
+from lldbsuite.test.decorators import *
+
+
+class ShortExprTestCase(AbstractBase.GenericTester):
+
+    mydir = AbstractBase.GenericTester.compute_mydir(__file__)
+
+    def test_short_type(self):
+        """Test that short-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('short.cpp', set(['short']))
+
+    @skipUnlessDarwin
+    def test_short_type_from_block(self):
+        """Test that short-type variables are displayed correctly from a block."""
+        self.build_and_run_expr('short.cpp', set(['short']), bc=True)
+
+    def test_unsigned_short_type(self):
+        """Test that 'unsigned_short'-type variable expressions are evaluated correctly."""
+        self.build_and_run_expr('unsigned_short.cpp',
+                                set(['unsigned', 'short']))
+
+    @skipUnlessDarwin
+    def test_unsigned_short_type_from_block(self):
+        """Test that 'unsigned short'-type variables are displayed correctly from a block."""
+        self.build_and_run_expr(
+            'unsigned_short.cpp', set(['unsigned', 'short']), bc=True)


        


More information about the lldb-commits mailing list