Search in sources :

Example 1 with LDAPCertStoreParameters

use of java.security.cert.LDAPCertStoreParameters in project robovm by robovm.

the class LDAPCertStoreParametersTest method testLDAPCertStoreParameters01.

//
// Tests
//
/**
     * Test #1 for <code>LDAPCertStoreParameters()</code> constructor<br>
     * Assertion: Creates an instance of <code>LDAPCertStoreParameters</code>
     * with the default parameter values (server name "localhost", port 389)
     */
public final void testLDAPCertStoreParameters01() {
    CertStoreParameters cp = new LDAPCertStoreParameters();
    assertTrue("isLDAPCertStoreParameters", cp instanceof LDAPCertStoreParameters);
}
Also used : CertStoreParameters(java.security.cert.CertStoreParameters) LDAPCertStoreParameters(java.security.cert.LDAPCertStoreParameters) LDAPCertStoreParameters(java.security.cert.LDAPCertStoreParameters)

Example 2 with LDAPCertStoreParameters

use of java.security.cert.LDAPCertStoreParameters in project robovm by robovm.

the class LDAPCertStoreParametersTest method testLDAPCertStoreParametersStringint02.

/**
     * Test #2 for <code>LDAPCertStoreParameters(String, int)</code> constructor<br>
     * Assertion: Creates an instance of <code>LDAPCertStoreParameters</code>
     * with the specified parameter values
     */
public final void testLDAPCertStoreParametersStringint02() {
    String serverName = "myhost";
    int portNumber = 1099;
    LDAPCertStoreParameters cp = new LDAPCertStoreParameters(serverName, portNumber);
    assertTrue("host", serverName.equals(cp.getServerName()));
    assertTrue("port", cp.getPort() == portNumber);
}
Also used : LDAPCertStoreParameters(java.security.cert.LDAPCertStoreParameters)

Example 3 with LDAPCertStoreParameters

use of java.security.cert.LDAPCertStoreParameters in project robovm by robovm.

the class LDAPCertStoreParametersTest method testToString.

/**
     * Test for <code>toString()</code> method<br>
     * Assertion: returns the formatted string describing parameters
     */
public final void testToString() {
    LDAPCertStoreParameters cp1 = new LDAPCertStoreParameters("myhost", 1101);
    assertNotNull(cp1.toString());
}
Also used : LDAPCertStoreParameters(java.security.cert.LDAPCertStoreParameters)

Example 4 with LDAPCertStoreParameters

use of java.security.cert.LDAPCertStoreParameters in project robovm by robovm.

the class LDAPCertStoreParametersTest method testLDAPCertStoreParameters02.

/**
     * Test #2 for <code>LDAPCertStoreParameters()</code> constructor<br>
     * Assertion: Creates an instance of <code>LDAPCertStoreParameters</code>
     * with the default parameter values (server name "localhost", port 389)
     */
public final void testLDAPCertStoreParameters02() {
    LDAPCertStoreParameters cp = new LDAPCertStoreParameters();
    assertEquals("host", "localhost", cp.getServerName());
    assertEquals("port", 389, cp.getPort());
}
Also used : LDAPCertStoreParameters(java.security.cert.LDAPCertStoreParameters)

Example 5 with LDAPCertStoreParameters

use of java.security.cert.LDAPCertStoreParameters in project robovm by robovm.

the class LDAPCertStoreParametersTest method testLDAPCertStoreParametersStringint01.

/**
     * Test #1 for <code>LDAPCertStoreParameters(String, int)</code> constructor<br>
     * Assertion: Creates an instance of <code>LDAPCertStoreParameters</code>
     * with the specified parameter values
     */
public final void testLDAPCertStoreParametersStringint01() {
    CertStoreParameters cp = new LDAPCertStoreParameters("myhost", 1098);
    assertTrue("isLDAPCertStoreParameters", cp instanceof LDAPCertStoreParameters);
}
Also used : CertStoreParameters(java.security.cert.CertStoreParameters) LDAPCertStoreParameters(java.security.cert.LDAPCertStoreParameters) LDAPCertStoreParameters(java.security.cert.LDAPCertStoreParameters)

Aggregations

LDAPCertStoreParameters (java.security.cert.LDAPCertStoreParameters)11 CertStoreParameters (java.security.cert.CertStoreParameters)3 NoSuchAlgorithmException (java.security.NoSuchAlgorithmException)1