public void Connect_WhenCredentialsNull_ThrowsArgumentNullException() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = null, Host = "tatata" }); }
public void Connect_WhenHostDoesNotExist_ThrowsServerConnectionException() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = new ServerCredential { Username = "******" }, Host = "tatata" }); }
public void Connect_WhenUsernameNull_ThrowsArgumentNullException() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = new ServerCredential { Username = null }, Host = "10.10.10.10" }); }
public void Connect_WhenHostNull_ThrowsArgumentNullException() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = new ServerCredential { Username = "******" }, Host = null }); }
public void Connect_WhenInvalidUsername_ThrowsServerConnectionException() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = new ServerCredential { Username = "******" }, Host = "10.10.10.10" }); }
public void Connect_WhenInvalidPassword_ThrowsServerConnectionException() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = new ServerCredential { Username = "******", Password = "******" }, Host = "10.10.10.10" }); }
public void Connect_WhenConnectionTimeOut_ThrowsSshOperationTimeoutException() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = new ServerCredential { Username = "******", Password = null }, Host = "10.10.10.10", Timeout = TimeSpan.Zero }); }
public void Connect_WhenValidUserAndPassword_IsConnected() { IServerConnectionService connection = new SSHConnectionService(); connection.Connect(new ServerConnection { Credential = new ServerCredential { Username = "******", Password = "" }, Host = "10.10.10.10" }); Assert.IsTrue(connection.IsConnected); }