MiniKdc { public int getPort() { return port; } MiniKdc(Properties conf, File workDir); static void main(String[] args); static Properties createConf(); void setTransport(String transport); int getPort(); String getHost(); String getRealm(); File getKrb5conf(); synchronized void start(); synchronized void stop(); synchronized void createPrincipal(String principal, String password); synchronized void createPrincipal(File keytabFile,
                                           String ... principals); static final String JAVA_SECURITY_KRB5_CONF; static final String SUN_SECURITY_KRB5_DEBUG; static final String ORG_NAME; static final String ORG_DOMAIN; static final String KDC_BIND_ADDRESS; static final String KDC_PORT; static final String INSTANCE; static final String MAX_TICKET_LIFETIME; static final String MIN_TICKET_LIFETIME; static final String MAX_RENEWABLE_LIFETIME; static final String TRANSPORT; static final String DEBUG; }
@Test public void testMiniKdcStart() { MiniKdc kdc = getKdc(); Assert.assertNotSame(0, kdc.getPort()); }