[Lldb-commits] [lldb] r249203 - Fix TestCompDirSymLink.py - remove existing symlink leftovers if previous test run

Oleksiy Vyalov via lldb-commits lldb-commits at lists.llvm.org
Fri Oct 2 15:37:55 PDT 2015


Author: ovyalov
Date: Fri Oct  2 17:37:55 2015
New Revision: 249203

URL: http://llvm.org/viewvc/llvm-project?rev=249203&view=rev
Log:
Fix TestCompDirSymLink.py - remove existing symlink leftovers if previous test run
was terminated (e.g., due timeout).

Modified:
    lldb/trunk/test/functionalities/breakpoint/comp_dir_symlink/TestCompDirSymLink.py

Modified: lldb/trunk/test/functionalities/breakpoint/comp_dir_symlink/TestCompDirSymLink.py
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/test/functionalities/breakpoint/comp_dir_symlink/TestCompDirSymLink.py?rev=249203&r1=249202&r2=249203&view=diff
==============================================================================
--- lldb/trunk/test/functionalities/breakpoint/comp_dir_symlink/TestCompDirSymLink.py (original)
+++ lldb/trunk/test/functionalities/breakpoint/comp_dir_symlink/TestCompDirSymLink.py Fri Oct  2 17:37:55 2015
@@ -47,6 +47,8 @@ class CompDirSymLinkTestCase(TestBase):
 
     def create_src_symlink(self):
         pwd_symlink = os.path.join(os.getcwd(), 'pwd_symlink')
+        if os.path.exists(pwd_symlink):
+          os.unlink(pwd_symlink)
         os.symlink(os.getcwd(), pwd_symlink)
         self.addTearDownHook(lambda: os.remove(pwd_symlink))
         return pwd_symlink




More information about the lldb-commits mailing list