[Lldb-commits] [lldb] r331886 - [lit, lldbsuite] Add a bug reference to the failing TestLinuxCore and fix an undefined property in dotest.py

Stella Stamenova via lldb-commits lldb-commits at lists.llvm.org
Wed May 9 08:35:19 PDT 2018


Author: stella.stamenova
Date: Wed May  9 08:35:19 2018
New Revision: 331886

URL: http://llvm.org/viewvc/llvm-project?rev=331886&view=rev
Log:
[lit, lldbsuite] Add a bug reference to the failing TestLinuxCore and fix an undefined property in dotest.py

Summary:
1) In TestLinuxCore rather than skipping the tests on Windows, mark them as expected failures and add a bug reference
2) In dotest.py replace the undefined property in the exceptions with the actual property causing the exception

Reviewers: asmith, labath, zturner

Reviewed By: labath, zturner

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D46590

Modified:
    lldb/trunk/packages/Python/lldbsuite/test/dotest.py
    lldb/trunk/packages/Python/lldbsuite/test/functionalities/postmortem/elf-core/TestLinuxCore.py

Modified: lldb/trunk/packages/Python/lldbsuite/test/dotest.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/dotest.py?rev=331886&r1=331885&r2=331886&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/dotest.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/dotest.py Wed May  9 08:35:19 2018
@@ -1208,11 +1208,11 @@ def run_suite():
             configuration.lldb_platform_working_dir, 448)  # 448 = 0o700
         if error.Fail():
             raise Exception("making remote directory '%s': %s" % (
-                remote_test_dir, error))
+                configuration.lldb_platform_working_dir, error))
 
         if not lldb.remote_platform.SetWorkingDirectory(
                 configuration.lldb_platform_working_dir):
-            raise Exception("failed to set working directory '%s'" % remote_test_dir)
+            raise Exception("failed to set working directory '%s'" % configuration.lldb_platform_working_dir)
         lldb.DBG.SetSelectedPlatform(lldb.remote_platform)
     else:
         lldb.remote_platform = None

Modified: lldb/trunk/packages/Python/lldbsuite/test/functionalities/postmortem/elf-core/TestLinuxCore.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/packages/Python/lldbsuite/test/functionalities/postmortem/elf-core/TestLinuxCore.py?rev=331886&r1=331885&r2=331886&view=diff
==============================================================================
--- lldb/trunk/packages/Python/lldbsuite/test/functionalities/postmortem/elf-core/TestLinuxCore.py (original)
+++ lldb/trunk/packages/Python/lldbsuite/test/functionalities/postmortem/elf-core/TestLinuxCore.py Wed May  9 08:35:19 2018
@@ -40,52 +40,52 @@ class LinuxCoreTestCase(TestBase):
         lldb.DBG.SetSelectedPlatform(self._initial_platform)
         super(LinuxCoreTestCase, self).tearDown()
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     @skipIf(triple='^mips')
     def test_i386(self):
         """Test that lldb can read the process information from an i386 linux core file."""
         self.do_test("linux-i386", self._i386_pid, self._i386_regions, "a.out")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     def test_mips_o32(self):
         """Test that lldb can read the process information from an MIPS O32 linux core file."""
         self.do_test("linux-mipsel-gnuabio32", self._mips_o32_pid,
                 self._mips_regions, "linux-mipsel-gn")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     def test_mips_n32(self):
         """Test that lldb can read the process information from an MIPS N32 linux core file """
         self.do_test("linux-mips64el-gnuabin32", self._mips64_n32_pid,
                 self._mips_regions, "linux-mips64el-")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     def test_mips_n64(self):
         """Test that lldb can read the process information from an MIPS N64 linux core file """
         self.do_test("linux-mips64el-gnuabi64", self._mips64_n64_pid,
                 self._mips_regions, "linux-mips64el-")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     @skipIf(triple='^mips')
     def test_ppc64le(self):
         """Test that lldb can read the process information from an ppc64le linux core file."""
         self.do_test("linux-ppc64le", self._ppc64le_pid, self._ppc64le_regions,
                 "linux-ppc64le.ou")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     @skipIf(triple='^mips')
     def test_x86_64(self):
         """Test that lldb can read the process information from an x86_64 linux core file."""
         self.do_test("linux-x86_64", self._x86_64_pid, self._x86_64_regions,
         "a.out")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     @skipIf(triple='^mips')
     def test_s390x(self):
         """Test that lldb can read the process information from an s390x linux core file."""
         self.do_test("linux-s390x", self._s390x_pid, self._s390x_regions,
         "a.out")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     @skipIf(triple='^mips')
     def test_same_pid_running(self):
         """Test that we read the information from the core correctly even if we have a running
@@ -113,7 +113,7 @@ class LinuxCoreTestCase(TestBase):
         self.do_test(self.getBuildArtifact("linux-x86_64-pid"), os.getpid(),
                 self._x86_64_regions, "a.out")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     @skipIf(triple='^mips')
     def test_two_cores_same_pid(self):
         """Test that we handle the situation if we have two core files with the same PID
@@ -143,7 +143,7 @@ class LinuxCoreTestCase(TestBase):
         self.do_test("linux-x86_64", self._x86_64_pid, self._x86_64_regions,
                 "a.out")
 
-    @skipIf(oslist=['windows'])
+    @expectedFailureAll(bugnumber="llvm.org/pr37371", hostoslist=["windows"])
     @skipIf(triple='^mips')
     def test_FPR_SSE(self):
         # check x86_64 core file




More information about the lldb-commits mailing list