LDAPDeleteTestCase.java revision db795dcd383e0b07a0c05a4e8875794dd86cd9a5
2033N/A * The contents of this file are subject to the terms of the 2033N/A * Common Development and Distribution License, Version 1.0 only 2033N/A * (the "License"). You may not use this file except in compliance 6983N/A * You can obtain a copy of the license at 2033N/A * See the License for the specific language governing permissions 2033N/A * and limitations under the License. 6983N/A * When distributing Covered Code, include this CDDL HEADER in each 6983N/A * file and include the License file at 6983N/A * add the following below this CDDL HEADER, with the fields enclosed 2033N/A * by brackets "[]" replaced with your own identifying information: 2033N/A * Portions Copyright [yyyy] [name of copyright owner] 2033N/A * Portions Copyright 2006-2007 Sun Microsystems, Inc. 2033N/A * A set of test cases for the LDAPDelete tool. 2033N/A // The path to a file containing an invalid bind password. 2033N/A // The path to a file containing a valid bind password. 2033N/A * Ensures that the Directory Server is running and performs other necessary 2033N/A * @throws Exception If an unexpected problem occurs. 2033N/A * Retrieves sets of invalid arguments that may not be used to initialize 3162N/A * @return Sets of invalid arguments that may not be used to initialize the "-D",
"cn=Directory Manager",
"-D",
"cn=Directory Manager",
"-J",
"1.2.3.4:invalidcriticality",
* Tests the LDAPDelete tool with sets of invalid arguments. * @param args The set of arguments to use for the LDAPDelete tool. * @param invalidReason The reason the provided set of arguments was * Tests a simple LDAPv2 delete. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests a simple LDAPv3 delete. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool using SSL with blind trust. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool using SSL with a trust store. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool using StartTLS with blind trust. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool using StartTLS with a trust store. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool using SASL PLAIN authentication. * @throws Exception If an unexpectd problem occurs. "-o",
"authid=dn:cn=Directory Manager",
* Tests deleting an entry that doesn't exist. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
"cn=Does Not Exist,o=test" * Tests deleting with a malformed DN. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests deleting an entry with one or more children but not including the * subtree delete control. * @throws Exception If an unexpectd problem occurs. "dn: uid=test.user,o=test",
"objectClass: organizationalPerson",
"objectClass: inetOrgPerson",
"userPassword: password");
"-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool reading a valid bind password from a file. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool reading an invalid bind password from a file. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool reading the bind password from a nonexistent * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool reading the DNs to delete from a file. Some of * the deletes will succeed and some will fail. * @throws Exception If an unexpectd problem occurs. "dn: uid=test.user,o=test",
"objectClass: organizationalPerson",
"objectClass: inetOrgPerson",
"userPassword: password");
"o=suffix does not exist",
"uid=entry does not exist,o=test",
"-D",
"cn=Directory Manager",
* Tests a subtree delete operation. * @throws Exception If an unexpectd problem occurs. "dn: uid=test.user,o=test",
"objectClass: organizationalPerson",
"objectClass: inetOrgPerson",
"userPassword: password");
"-D",
"cn=Directory Manager",
* Tests a subtree delete operation using an alternate name for the control. * @throws Exception If an unexpectd problem occurs. "dn: uid=test.user,o=test",
"objectClass: organizationalPerson",
"objectClass: inetOrgPerson",
"userPassword: password");
"-D",
"cn=Directory Manager",
"-J",
"subtreedelete:true",
* Tests a simple delete using the client-side no-op option. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests a simple delete using the server-side no-op control. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests a simple delete using the server-side no-op control with an alternate * name for the no-op control. * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the inclusion of multiple arbitrary controls in the request to the * @throws Exception If an unexpectd problem occurs. "-D",
"cn=Directory Manager",
* Tests the LDAPDelete tool with the "--help" option.