def test_open_auth_ignored(self):
def req(credentials, user_data):
for cred in credentials:
if cred[0] == libvirt.VIR_CRED_AUTHNAME:
cred[4] = 'convirt'
elif cred[0] == libvirt.VIR_CRED_PASSPHRASE:
cred[4] = 'ignored'
return 0
auth = [[libvirt.VIR_CRED_AUTHNAME, libvirt.VIR_CRED_PASSPHRASE],
req, None]
conn = convirt.openAuth('convirt:///system', auth)
self.assertTrue(conn)
评论列表
文章目录