コード例 #1
0
def test_channel():
    channel = OAuthSSHChannel(hostname='spce01.sdcc.bnl.gov',
                              port=2222,
                              username='******')
    x, stdout, stderr = channel.execute_wait('ls')
    print(x, stdout, stderr)
    assert x == 0, "Expected exit code 0, got {}".format(x)
コード例 #2
0
def test_channel():
    channel = OAuthSSHChannel(hostname='ssh.demo.globus.org',
                              username='******')
    x, stdout, stderr = channel.execute_wait('ls')
    print(x, stdout, stderr)
    assert x == 0, "Expected exit code 0, got {}".format(x)