public void Credential_Set_Success() { var connection = new SubDirectoryConnection { Credential = new NetworkCredential("username", "password") }; connection.Credential = null; }
public void Timeout_SetValid_GetReturnsExpected() { var connection = new SubDirectoryConnection { Timeout = TimeSpan.Zero }; Assert.Equal(TimeSpan.Zero, connection.Timeout); }
public void Ctor_Default() { var connection = new SubDirectoryConnection(); Assert.Empty(connection.ClientCertificates); Assert.Null(connection.Directory); Assert.Equal(new TimeSpan(0, 0, 30), connection.Timeout); }
public void Timeout_SetNegative_ThrowsArgumentException() { var connection = new SubDirectoryConnection(); Assert.Throws <ArgumentException>("value", () => connection.Timeout = TimeSpan.FromTicks(-1)); }