def tearDown(self): for f in ["dsa_test.pub", "dsa_test", "kh_test"]: try: os.remove(f) except: pass return SFTPTestBase.tearDown(self)
def tearDown(self): for f in ['dsa_test.pub', 'dsa_test', 'kh_test']: try: os.remove(f) except: pass return SFTPTestBase.tearDown(self)
def tearDown(self): for f in ["dsa_test.pub", "dsa_test", "kh_test"]: try: os.remove(f) except BaseException: pass return SFTPTestBase.tearDown(self)
def setUp(self): with open('dsa_test.pub', 'wb') as f: f.write(test_ssh.publicDSA_openssh) with open('dsa_test', 'wb') as f: f.write(test_ssh.privateDSA_openssh) os.chmod('dsa_test', 33152) with open('kh_test', 'wb') as f: f.write(b'127.0.0.1 ' + test_ssh.publicRSA_openssh) return SFTPTestBase.setUp(self)
def setUp(self): with open("dsa_test.pub", "wb") as f: f.write(test_ssh.publicDSA_openssh) with open("dsa_test", "wb") as f: f.write(test_ssh.privateDSA_openssh) os.chmod("dsa_test", 33152) with open("kh_test", "wb") as f: f.write(b"127.0.0.1 " + test_ssh.publicRSA_openssh) return SFTPTestBase.setUp(self)
def setUp(self): with open("dsa_test.pub", "w") as f: f.write(test_ssh.publicDSA_openssh) with open("dsa_test", "w") as f: f.write(test_ssh.privateDSA_openssh) os.chmod("dsa_test", 33152) with open("kh_test", "w") as f: f.write("127.0.0.1 " + test_ssh.publicRSA_openssh) return SFTPTestBase.setUp(self)
def setUp(self): f = open('dsa_test.pub','w') f.write(test_ssh.publicDSA_openssh) f.close() f = open('dsa_test','w') f.write(test_ssh.privateDSA_openssh) f.close() os.chmod('dsa_test', 33152) f = open('kh_test','w') f.write('127.0.0.1 ' + test_ssh.publicRSA_openssh) f.close() return SFTPTestBase.setUp(self)
def setUp(self): f = open("dsa_test.pub", "w") f.write(test_ssh.publicDSA_openssh) f.close() f = open("dsa_test", "w") f.write(test_ssh.privateDSA_openssh) f.close() os.chmod("dsa_test", 33152) f = open("kh_test", "w") f.write("127.0.0.1 " + test_ssh.publicRSA_openssh) f.close() return SFTPTestBase.setUp(self)