|
@@ -49,8 +49,8 @@ class FakeTarget(object):
|
|
|
def exportStart(self):
|
|
|
self.sshlog = os.path.join(self.testdir, "ssh_target_log.%s" % self.datetime)
|
|
|
sshloglink = os.path.join(self.testdir, "ssh_target_log")
|
|
|
- if os.path.islink(sshloglink):
|
|
|
- os.unlink(sshloglink)
|
|
|
+ if os.path.exists(sshloglink):
|
|
|
+ os.remove(sshloglink)
|
|
|
os.symlink(self.sshlog, sshloglink)
|
|
|
print("SSH log file: %s" % self.sshlog)
|
|
|
self.connection = SSHControl(self.ip, logfile=self.sshlog)
|