Example #1
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test @Category(TimeoutTests.class) public void shouldTimeoutIfLdapServerDoesNotRespondWithoutConnectionPooling() throws java.io.IOException
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
        public virtual void ShouldTimeoutIfLdapServerDoesNotRespondWithoutConnectionPooling()
        {
            using (DirectoryServiceWaitOnSearch ignore = new DirectoryServiceWaitOnSearch(this, 5000))
            {
                RestartServerWithOverriddenSettings(SecuritySettings.ldap_read_timeout.name(), "1s", SecuritySettings.ldap_authorization_connection_pooling.name(), "false", SecuritySettings.ldap_authorization_use_system_account.name(), "true");

                AssertReadFails("neo", "abc123");
            }
        }
Example #2
0
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @Test @Category(TimeoutTests.class) public void shouldTimeoutIfLdapServerDoesNotRespondWithLdapUserContext() throws java.io.IOException
//JAVA TO C# CONVERTER WARNING: Method 'throws' clauses are not available in C#:
        public virtual void ShouldTimeoutIfLdapServerDoesNotRespondWithLdapUserContext()
        {
            using (DirectoryServiceWaitOnSearch ignore = new DirectoryServiceWaitOnSearch(this, 5000))
            {
                // When
                RestartServerWithOverriddenSettings(SecuritySettings.ldap_read_timeout.name(), "1s");

                try
                {
                    ConnectDriver("neo", "abc123");
                    fail("should have timed out");
                }
                catch (TransientException e)
                {
                    assertThat(e.Message, equalTo(LdapRealm.LDAP_READ_TIMEOUT_CLIENT_MESSAGE));
                }
            }
        }
Example #3
0
 public BaseInterceptorAnonymousInnerClass(DirectoryServiceWaitOnSearch outerInstance, long waitingTimeMillis)
 {
     this.outerInstance      = outerInstance;
     this._waitingTimeMillis = waitingTimeMillis;
 }