From ea6562a367d6b90ec4340b44f49baea7a73b53ed Mon Sep 17 00:00:00 2001
From: el_kaboing <el_kaboing@localhost>
Date: Thu, 07 Dec 2006 15:11:14 +0000
Subject: [PATCH] Some general cleanup of Security functional tests. Previously, some of the test suites cleaned up after they were done by deleting the entries that were specific to them. Now all the Security test suites clean up their entries.
---
opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_teardown_pwd_policy.xml | 67 +++++++++++
opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_pwd_validator.xml | 4
opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_teardown_pwd_validator.xml | 67 +++++++++++
opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_teardown_account_activation.xml | 67 +++++++++++
opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_pwd_storage.xml | 4
opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_teardown_pwd_storage.xml | 67 +++++++++++
opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_pwd_policy.xml | 4
opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_teardown_bind_no_pwd.xml | 67 +++++++++++
opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_account_activation.xml | 4
opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_bind_no_pwd.xml | 4
10 files changed, 355 insertions(+), 0 deletions(-)
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_account_activation.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_account_activation.xml
index 24346f4..094ffe7 100755
--- a/opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_account_activation.xml
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_account_activation.xml
@@ -76,6 +76,10 @@
file="'%s/testcases/security/account_activation/security_test_account.xml' % (TESTS_DIR)"/>
<call function="'test_account'" />
+ <import machine="'%s' % (STAF_LOCAL_HOSTNAME)"
+ file="'%s/testcases/security/account_activation/security_teardown_account_activation.xml' % (TESTS_DIR)"/>
+ <call function="'teardown_account_activation'" />
+
<!--- Stop DS -->
<sequence>
<message>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_teardown_account_activation.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_teardown_account_activation.xml
new file mode 100755
index 0000000..7ddb4d6
--- /dev/null
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/account_activation/security_teardown_account_activation.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE stax SYSTEM "stax.dtd">
+<!---
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE
+ * or https://OpenDS.dev.java.net/OpenDS.LICENSE.
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE. 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
+ *
+ *
+ * Portions Copyright 2006 Sun Microsystems, Inc.
+ -->
+<stax>
+
+ <defaultcall function="teardown_account_activation"/>
+
+ <function name="teardown_account_activation">
+
+ <sequence>
+
+ <!--- Test Case : Password Policy Teardown -->
+ <!--- Delete Branch -->
+ <testcase name="'Security: Acct Act: Postamble Reset'">
+ <sequence>
+ <message>
+ 'Security: Acct Act: Postamble - Deleting Branch'
+ </message>
+
+ <call function="'DeleteEntry'">
+ { 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
+ 'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
+ 'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
+ 'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
+ 'dsBaseDN' : 'o=Account Activation Tests,dc=example,dc=com' ,
+ 'extraParams' : '-x'}
+ </call>
+
+ <call function="'checkRC'">
+ { 'returncode' : RC ,
+ 'result' : STAXResult }
+ </call>
+ </sequence>
+ </testcase>
+
+ <return>RC</return>
+
+ </sequence>
+
+ </function>
+
+</stax>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_bind_no_pwd.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_bind_no_pwd.xml
index 96314f2..31bccec 100755
--- a/opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_bind_no_pwd.xml
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_bind_no_pwd.xml
@@ -76,6 +76,10 @@
file="'%s/testcases/security/bind_no_pwd/security_pwd_null.xml' % (TESTS_DIR)"/>
<call function="'pwd_null'" />
+ <import machine="'%s' % (STAF_LOCAL_HOSTNAME)"
+ file="'%s/testcases/security/bind_no_pwd/security_teardown_bind_no_pwd.xml' % (TESTS_DIR)"/>
+ <call function="'teardown_bind_no_pwd'" />
+
<!--- Stop DS -->
<sequence>
<message>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_teardown_bind_no_pwd.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_teardown_bind_no_pwd.xml
new file mode 100755
index 0000000..55248ad
--- /dev/null
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/bind_no_pwd/security_teardown_bind_no_pwd.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE stax SYSTEM "stax.dtd">
+<!---
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE
+ * or https://OpenDS.dev.java.net/OpenDS.LICENSE.
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE. 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
+ *
+ *
+ * Portions Copyright 2006 Sun Microsystems, Inc.
+ -->
+<stax>
+
+ <defaultcall function="teardown_bind_no_pwd"/>
+
+ <function name="teardown_bind_no_pwd">
+
+ <sequence>
+
+ <!--- Test Case : Password Policy Teardown -->
+ <!--- Delete Branch -->
+ <testcase name="'Security: Bind No Pwd: Postamble Reset'">
+ <sequence>
+ <message>
+ 'Security: Bind No Pwd: Postamble - Deleting Branch'
+ </message>
+
+ <call function="'DeleteEntry'">
+ { 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
+ 'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
+ 'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
+ 'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
+ 'dsBaseDN' : 'o=Bind No Pwd Tests,dc=example,dc=com' ,
+ 'extraParams' : '-x'}
+ </call>
+
+ <call function="'checkRC'">
+ { 'returncode' : RC ,
+ 'result' : STAXResult }
+ </call>
+ </sequence>
+ </testcase>
+
+ <return>RC</return>
+
+ </sequence>
+
+ </function>
+
+</stax>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_pwd_policy.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_pwd_policy.xml
index 5a10a7b..5fbb203 100755
--- a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_pwd_policy.xml
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_pwd_policy.xml
@@ -116,6 +116,10 @@
file="'%s/testcases/security/pwd_policy/security_lockout_duration.xml' % (TESTS_DIR)"/>
<call function="'lockout_duration'" />
+ <import machine="'%s' % (STAF_LOCAL_HOSTNAME)"
+ file="'%s/testcases/security/pwd_policy/security_teardown_pwd_policy.xml' % (TESTS_DIR)"/>
+ <call function="'teardown_pwd_policy'" />
+
<!--- Stop DS -->
<sequence>
<message>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_teardown_pwd_policy.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_teardown_pwd_policy.xml
new file mode 100755
index 0000000..2b64b98
--- /dev/null
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_policy/security_teardown_pwd_policy.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE stax SYSTEM "stax.dtd">
+<!---
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE
+ * or https://OpenDS.dev.java.net/OpenDS.LICENSE.
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE. 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
+ *
+ *
+ * Portions Copyright 2006 Sun Microsystems, Inc.
+ -->
+<stax>
+
+ <defaultcall function="teardown_pwd_policy"/>
+
+ <function name="teardown_pwd_policy">
+
+ <sequence>
+
+ <!--- Test Case : Password Policy Teardown -->
+ <!--- Delete Branch -->
+ <testcase name="'Security: Pwd Policy: Postamble Reset'">
+ <sequence>
+ <message>
+ 'Security: Pwd Policy: Postamble - Deleting Branch'
+ </message>
+
+ <call function="'DeleteEntry'">
+ { 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
+ 'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
+ 'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
+ 'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
+ 'dsBaseDN' : 'o=Pwd Policy Tests,dc=example,dc=com' ,
+ 'extraParams' : '-x'}
+ </call>
+
+ <call function="'checkRC'">
+ { 'returncode' : RC ,
+ 'result' : STAXResult }
+ </call>
+ </sequence>
+ </testcase>
+
+ <return>RC</return>
+
+ </sequence>
+
+ </function>
+
+</stax>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_pwd_storage.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_pwd_storage.xml
index eead1c4..e00691e 100755
--- a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_pwd_storage.xml
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_pwd_storage.xml
@@ -108,6 +108,10 @@
file="'%s/testcases/security/pwd_storage/security_pwd_CLEAR.xml' % (TESTS_DIR)"/>
<call function="'pwd_CLEAR'" />
+ <import machine="'%s' % (STAF_LOCAL_HOSTNAME)"
+ file="'%s/testcases/security/pwd_storage/security_teardown_pwd_storage.xml' % (TESTS_DIR)"/>
+ <call function="'teardown_pwd_storage'" />
+
<!--- Stop DS -->
<sequence>
<message>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_teardown_pwd_storage.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_teardown_pwd_storage.xml
new file mode 100755
index 0000000..1e90d18
--- /dev/null
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_storage/security_teardown_pwd_storage.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE stax SYSTEM "stax.dtd">
+<!---
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE
+ * or https://OpenDS.dev.java.net/OpenDS.LICENSE.
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE. 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
+ *
+ *
+ * Portions Copyright 2006 Sun Microsystems, Inc.
+ -->
+<stax>
+
+ <defaultcall function="teardown_pwd_storage"/>
+
+ <function name="teardown_pwd_storage">
+
+ <sequence>
+
+ <!--- Test Case : Password Policy Teardown -->
+ <!--- Delete Branch -->
+ <testcase name="'Security: Pwd Storage: Postamble Reset'">
+ <sequence>
+ <message>
+ 'Security: Pwd Storage: Postamble - Deleting Branch'
+ </message>
+
+ <call function="'DeleteEntry'">
+ { 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
+ 'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
+ 'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
+ 'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
+ 'dsBaseDN' : 'o=Pwd Storage Tests,dc=example,dc=com' ,
+ 'extraParams' : '-x'}
+ </call>
+
+ <call function="'checkRC'">
+ { 'returncode' : RC ,
+ 'result' : STAXResult }
+ </call>
+ </sequence>
+ </testcase>
+
+ <return>RC</return>
+
+ </sequence>
+
+ </function>
+
+</stax>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_pwd_validator.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_pwd_validator.xml
index 2d6ded2..e1c822a 100755
--- a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_pwd_validator.xml
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_pwd_validator.xml
@@ -80,6 +80,10 @@
file="'%s/testcases/security/pwd_validator/security_skip_val_for_admins.xml' % (TESTS_DIR)"/>
<call function="'skip_val_for_admins'" />
+ <import machine="'%s' % (STAF_LOCAL_HOSTNAME)"
+ file="'%s/testcases/security/pwd_validator/security_teardown_pwd_validator.xml' % (TESTS_DIR)"/>
+ <call function="'teardown_pwd_validator'" />
+
<!--- Stop DS -->
<sequence>
<message>
diff --git a/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_teardown_pwd_validator.xml b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_teardown_pwd_validator.xml
new file mode 100755
index 0000000..815eb10
--- /dev/null
+++ b/opendj-sdk/opends/tests/functional-tests/testcases/security/pwd_validator/security_teardown_pwd_validator.xml
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!DOCTYPE stax SYSTEM "stax.dtd">
+<!---
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE
+ * or https://OpenDS.dev.java.net/OpenDS.LICENSE.
+ * 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
+ * trunk/opends/resource/legal-notices/OpenDS.LICENSE. 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
+ *
+ *
+ * Portions Copyright 2006 Sun Microsystems, Inc.
+ -->
+<stax>
+
+ <defaultcall function="teardown_pwd_validator"/>
+
+ <function name="teardown_pwd_validator">
+
+ <sequence>
+
+ <!--- Test Case : Password Policy Teardown -->
+ <!--- Delete Branch -->
+ <testcase name="'Security: Pwd Validator: Postamble Reset'">
+ <sequence>
+ <message>
+ 'Security: Pwd Validator: Postamble - Deleting Branch'
+ </message>
+
+ <call function="'DeleteEntry'">
+ { 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
+ 'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
+ 'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
+ 'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
+ 'dsBaseDN' : 'o=Pwd Validator Tests,dc=example,dc=com' ,
+ 'extraParams' : '-x'}
+ </call>
+
+ <call function="'checkRC'">
+ { 'returncode' : RC ,
+ 'result' : STAXResult }
+ </call>
+ </sequence>
+ </testcase>
+
+ <return>RC</return>
+
+ </sequence>
+
+ </function>
+
+</stax>
--
Gitblit v1.10.0