InternalSearchOperationTestCase.java revision ea1068c292e9b341af6d6b563cd8988a96be20a9
/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at legal-notices/CDDLv1_0.txt
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at legal-notices/CDDLv1_0.txt.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information:
* Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*
*
* Copyright 2006-2008 Sun Microsystems, Inc.
* Portions Copyright 2014-2015 ForgeRock AS
*/
/**
* This class defines a set of tests for the
* org.opends.server.protocols.internal.InternalSearchOperation class.
*/
public class InternalSearchOperationTestCase
extends InternalTestCase
{
/**
* Ensures that the Directory Server is running.
*
* @throws Exception If an unexpected problem occurs.
*/
public void startServer()
throws Exception
{
}
/**
* Tests the first constructor, which takes raw arguments, without providing
* an internal search listener.
*
* @throws Exception If an unexpected problem occurs.
*/
@Test
public void testConstructor1WithoutListener() throws Exception
{
}
/**
* Tests the first constructor, which takes raw arguments, with an internal
* search listener.
*
* @throws Exception If an unexpected problem occurs.
*/
@Test
public void testConstructor1WithListener() throws Exception
{
new InternalSearchOperation(getRootConnection(), nextOperationID(), nextMessageID(), request, new TestInternalSearchListener());
}
/**
* Tests the <CODE>getSearchEntries</CODE> and
* <CODE>getSearchReferences</CODE> methods.
*
* @throws Exception If an unexpected problem occurs.
*/
@Test
public void testGetSearchEntriesAndReferences() throws Exception
{
}
/**
* Tests the <CODE>addSearchEntry</CODE> method without a search listener.
*
* @throws Exception If an unexpected problem occurs.
*/
@Test
public void testAddSearchEntryWithoutListener() throws Exception
{
"objectClass: top",
"objectClass: ds-root-dse");
}
/**
* Tests the <CODE>addSearchEntry</CODE> method with a search listener.
*
* @throws Exception If an unexpected problem occurs.
*/
@Test
public void testAddSearchEntryWithListener() throws Exception
{
getRootConnection(), nextOperationID(), nextMessageID(), request, new TestInternalSearchListener());
"objectClass: top",
"objectClass: ds-root-dse");
}
/**
* Tests the <CODE>addSearchReference</CODE> method without a search listener.
*
* @throws Exception If an unexpected problem occurs.
*/
@Test
public void testAddSearchReferenceWithoutListener() throws Exception
{
new SearchResultReference("ldap://server.example.com:389/");
}
/**
* Tests the <CODE>addSearchReference</CODE> method with a search listener.
*
* @throws Exception If an unexpected problem occurs.
*/
@Test
public void testAddSearchReferenceWithListener() throws Exception
{
getRootConnection(), nextOperationID(), nextMessageID(), request, new TestInternalSearchListener());
new SearchResultReference("ldap://server.example.com:389/");
}
}