[lldb] Stop unsetting LLDB_DEBUGSERVER_PATH from TestLaunchProcessPosixSpawn
authorJonas Devlieghere <jonas@devlieghere.com>
Mon, 19 Apr 2021 19:24:58 +0000 (12:24 -0700)
committerJonas Devlieghere <jonas@devlieghere.com>
Mon, 19 Apr 2021 19:28:22 +0000 (12:28 -0700)
We no longer need this after Pavel's change to automatically find debug
servers to test. (3ca7b2d)

lldb/test/API/macosx/posix_spawn/TestLaunchProcessPosixSpawn.py

index fc26de7..1215570 100644 (file)
@@ -17,17 +17,6 @@ def apple_silicon():
     return "Apple M" in features.decode('utf-8')
 
 
-@contextlib.contextmanager
-def remove_from_env(var):
-    old_environ = os.environ.copy()
-    del os.environ[var]
-    try:
-        yield
-    finally:
-        os.environ.clear()
-        os.environ.update(old_environ)
-
-
 class TestLaunchProcessPosixSpawn(TestBase):
     NO_DEBUG_INFO_TESTCASE = True
     mydir = TestBase.compute_mydir(__file__)
@@ -67,9 +56,5 @@ class TestLaunchProcessPosixSpawn(TestBase):
     def test_apple_silicon(self):
         self.build()
         exe = self.getBuildArtifact("fat.out")
-
-        # We need to remove LLDB_DEBUGSERVER_PATH from the environment if it's
-        # set so that the Rosetta debugserver is picked for x86_64.
-        with remove_from_env('LLDB_DEBUGSERVER_PATH'):
-            self.run_arch(exe, 'x86_64')
-            self.run_arch(exe, 'arm64')
+        self.run_arch(exe, 'x86_64')
+        self.run_arch(exe, 'arm64')