| | |
| | | |
| | | <!--- Test Suite information |
| | | #@TestSuiteName Replication Schema Replication Tests |
| | | #@TestSuitePurpose Verify that the schema is replicated as any other suffix in a replicated topology. |
| | | #@TestSuitePurpose Verify that the schema is replicated as any |
| | | other suffix in a replicated topology. |
| | | #@TestSuiteID Schema Replication Tests |
| | | #@TestSuiteGroup Schema Replication |
| | | #@TestGroup Replication |
| | |
| | | |
| | | |
| | | <import machine="STAF_LOCAL_HOSTNAME" |
| | | file="'%s/testcases/replication/replication_setup.xml' % (TESTS_DIR)"/> |
| | | file="'%s/testcases/replication/replication_setup.xml' % TESTS_DIR"/> |
| | | <call function="'replication_setup'" /> |
| | | |
| | | <script> |
| | |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Add objectclass |
| | | #@TestID Add objectclass |
| | | #@TestPurpose Check schema replication when a new objectclass is added |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestPurpose Check schema replication when a new objectclass |
| | | is added |
| | | #@TestPreamble Load entries |
| | | #@TestSteps Add new objectclass definition on server1 |
| | | #@TestSteps Add entry of new objectclass on server2 |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema add and entry add replicated |
| | | --> |
| | | <testcase name="getTestCaseName('Add objectclass')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Add objectclass. Check schema replication when a new objectclass is added' |
| | | 'Replication: Schema Replication: Add objectclass. \ |
| | | Check schema replication when a new objectclass is added' |
| | | </message> |
| | | |
| | | <!-- Load entries into "master" server --> |
| | |
| | | 'dsInstancePort' : master.getPort(), |
| | | 'dsInstanceDn' : master.getRootDn(), |
| | | 'dsInstancePswd' : master.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/Example.ldif' % clientDataDir } |
| | | 'entryToBeAdded' : '%s/replication/Example.ldif' % \ |
| | | clientDataDir |
| | | } |
| | | </call> |
| | | |
| | | <script> |
| | |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : newObjectclass, |
| | | 'changetype' : 'add' } |
| | | 'changetype' : 'add' |
| | | } |
| | | </call> |
| | | |
| | | <!-- Add entry to "consumer" server --> |
| | |
| | | 'dsInstancePort' : consumer.getPort(), |
| | | 'dsInstanceDn' : consumer.getRootDn(), |
| | | 'dsInstancePswd' : consumer.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/testuser-0.ldif' % clientDataDir } |
| | | 'entryToBeAdded' : '%s/replication/testuser-0.ldif' % \ |
| | | clientDataDir |
| | | } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers |
| | | in the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <script> |
| | | knownIssue(2599) |
| | | </script> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Add attributetype |
| | | #@TestName Replication: Schema Replication: |
| | | Add attributetype |
| | | #@TestID Add attributetype |
| | | #@TestPurpose Check schema replication when a new attributetype is added |
| | | #@TestPurpose Check schema replication when a new |
| | | attributetype is added |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestSteps Add new attributeType and new objectclass |
| | | definition on server1 |
| | | #@TestSteps Add new entry containing new objectclass and |
| | | new attributeType on server2 |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema add and entry adds replicated |
| | | --> |
| | | <testcase name="getTestCaseName('Add attributetype')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Add attributetype Check schema replication when a new attributetype is added' |
| | | 'Replication: Schema Replication: Add attributetype Check \ |
| | | schema replication when a new attributetype is added' |
| | | </message> |
| | | |
| | | <script> |
| | |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'attributeTypes', |
| | | 'newAttributeValue' : newAttributetype, |
| | | 'changetype' : 'add' } |
| | | 'changetype' : 'add' |
| | | } |
| | | </call> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : masterPath, |
| | |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : newObjectclass, |
| | | 'changetype' : 'add' } |
| | | 'changetype' : 'add' |
| | | } |
| | | </call> |
| | | |
| | | <!-- Add entry to "consumer" server --> |
| | |
| | | 'dsInstancePort' : consumer.getPort(), |
| | | 'dsInstanceDn' : consumer.getRootDn(), |
| | | 'dsInstancePswd' : consumer.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/testuser-1.ldif' % clientDataDir } |
| | | 'entryToBeAdded' : '%s/replication/testuser-1.ldif' % \ |
| | | clientDataDir |
| | | } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers in |
| | | the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <script> |
| | | knownIssue(2599) |
| | | </script> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | |
| | | |
| | | <!-- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Delete objectclass |
| | | #@TestName Replication: Schema Replication: |
| | | Delete objectclass |
| | | #@TestID Delete objectclass |
| | | #@TestPurpose Check schema replication when an objectclass is deleted |
| | | #@TestPurpose Check schema replication when an objectclass |
| | | is deleted |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestSteps Remove user-defined objectclass definition on |
| | | server1 |
| | | #@TestSteps Delete entry on server1 |
| | | #@TestSteps Add entry containing removed objectclass on |
| | | every server |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema remove replicated and last |
| | | entry add rejected on all servers (error 65: |
| | | objectclass violation) |
| | | --> |
| | | <testcase name="getTestCaseName('Delete objectclass')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Delete objectclass Check schema replication when an objectclass is deleted' |
| | | 'Replication: Schema Replication: Delete objectclass Check \ |
| | | schema replication when an objectclass is deleted' |
| | | </message> |
| | | |
| | | <script> |
| | |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : newObjectclass, |
| | | 'changetype' : 'delete' } |
| | | 'changetype' : 'delete' |
| | | } |
| | | </call> |
| | | |
| | | <!-- Delete previously added entry --> |
| | |
| | | } |
| | | </call> |
| | | |
| | | <!-- Try to add entry to servers; should be rejected with error 65 (objectclass violation) --> |
| | | <!-- Try to add entry to servers; should be rejected with error 65 |
| | | (objectclass violation) --> |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/testuser-0.ldif' % clientDataDir, |
| | | 'expectedRC' : 65 } |
| | | 'entryToBeAdded' : '%s/replication/testuser-0.ldif' % \ |
| | | clientDataDir, |
| | | 'expectedRC' : 65 |
| | | } |
| | | </call> |
| | | </iterate> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers in |
| | | the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <script> |
| | | knownIssue(2599) |
| | | </script> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | |
| | | |
| | | <!-- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Modify objectclass |
| | | #@TestName Replication: Schema Replication: |
| | | Modify objectclass |
| | | #@TestID Modify objectclass |
| | | #@TestPurpose Check schema replication when an objectclass is modified |
| | | #@TestPurpose Check schema replication when an objectclass is |
| | | modified |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestSteps Remove user-defined objectclass definition on |
| | | server1 |
| | | #@TestSteps Add modified version of removed user-defined |
| | | objectclass on server1 (make attributes |
| | | MANDATORY) |
| | | #@TestSteps Add entry containing newly added objectclass but |
| | | without required attributes on every server |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema modify replicated and entry |
| | | add rejected with error 65 (objectclass |
| | | violation) on all servers |
| | | --> |
| | | <testcase name="getTestCaseName('Modify objectclass')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Modify objectclass Check schema replication when an objectclass is modified' |
| | | 'Replication: Schema Replication: Modify objectclass Check \ |
| | | schema replication when an objectclass is modified' |
| | | </message> |
| | | |
| | | <script> |
| | |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : oldObjectclass, |
| | | 'changetype' : 'delete' } |
| | | 'changetype' : 'delete' |
| | | } |
| | | </call> |
| | | <call function="'modifyAnAttribute'"> |
| | | { 'dsPath' : masterPath, |
| | |
| | | 'DNToModify' : 'cn=schema', |
| | | 'attributeName' : 'objectClasses', |
| | | 'newAttributeValue' : newObjectclass, |
| | | 'changetype' : 'add' } |
| | | 'changetype' : 'add' |
| | | } |
| | | </call> |
| | | |
| | | <!-- Try to add entry to servers; should be rejected with error 65 (objectclass violation) --> |
| | | <!-- Try to add entry to servers; should be rejected with error 65 |
| | | (objectclass violation) --> |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/testuser-2.ldif' % clientDataDir, |
| | | 'expectedRC' : 65 } |
| | | 'entryToBeAdded' : '%s/replication/testuser-2.ldif' % \ |
| | | clientDataDir, |
| | | 'expectedRC' : 65 |
| | | } |
| | | </call> |
| | | </iterate> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers in |
| | | the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <script> |
| | | knownIssue(2599) |
| | | </script> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Add objectclass (edit schema file) |
| | | #@TestName Replication: Schema Replication: Add objectclass |
| | | (edit schema file) |
| | | #@TestID Add objectclass (edit schema file) |
| | | #@TestPurpose Check schema replication when a new objectclass is added manually |
| | | #@TestPurpose Check schema replication when a new objectclass |
| | | is added manually |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestSteps Stop servers |
| | | #@TestSteps Edit 99-user.ldif to add new objectclass |
| | | definition on server1 |
| | | #@TestSteps Start servers |
| | | #@TestSteps Add entry of new objectclass on server2 |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema add and entry add replicated |
| | | --> |
| | | <testcase name="getTestCaseName('Add objectclass (edit schema file)')"> |
| | | <testcase name="getTestCaseName |
| | | ('Add objectclass (edit schema file)')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Add objectclass (edit schema file). Check schema replication when a new objectclass is added manually' |
| | | 'Replication: Schema Replication: Add objectclass (edit \ |
| | | schema file). Check schema replication when a new objectclass \ |
| | | is added manually' |
| | | </message> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | |
| | | <!-- Modify schema in "master" server --> |
| | | <call function="'copyFile'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : masterHost, |
| | | 'srcfile' : currentSchemaFile, |
| | | 'destfile' : provSchemaFile } |
| | | 'destfile' : provSchemaFile |
| | | } |
| | | </call> |
| | | <call function="'LdifModifyWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'sourceLdif' : provSchemaFile, |
| | | 'changesLdif' : '%s/replication/schemamods-0.ldif' % masterDataDir, |
| | | 'targetLdif' : currentSchemaFile } |
| | | 'changesLdif' : '%s/replication/schemamods-0.ldif' % \ |
| | | masterDataDir, |
| | | 'targetLdif' : currentSchemaFile |
| | | } |
| | | </call> |
| | | |
| | | <!-- Start the servers in the topology --> |
| | |
| | | |
| | | <call function="'Sleep'"> |
| | | { 'location' : masterHost, |
| | | 'sleepForMilliSeconds' : 1000 } |
| | | 'sleepForMilliSeconds' : 1000 |
| | | } |
| | | </call> |
| | | |
| | | <!-- Add entry to "consumer" server --> |
| | |
| | | 'dsInstancePort' : consumer.getPort(), |
| | | 'dsInstanceDn' : consumer.getRootDn(), |
| | | 'dsInstancePswd' : consumer.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-0.ldif' % clientDataDir } |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-0.ldif' % \ |
| | | clientDataDir |
| | | } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers in |
| | | the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <script> |
| | | knownIssue(2599) |
| | | </script> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | |
| | | |
| | | <!--- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Add attributetype (edit schema file) |
| | | #@TestName Replication: Schema Replication: Add |
| | | attributetype (edit schema file) |
| | | #@TestID Add attributetype (edit schema file) |
| | | #@TestPurpose Check schema replication when a new attributetype is added manually |
| | | #@TestPurpose Check schema replication when a new |
| | | attributetype is added manually |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestSteps Stop servers |
| | | #@TestSteps Edit 99-user.ldif to add new objectclass and |
| | | new attributeType definition on server1 |
| | | #@TestSteps Start servers |
| | | #@TestSteps Add new entry containing new objectclass and |
| | | new attributeType on server2 |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema add and entry adds replicated |
| | | --> |
| | | <testcase name="getTestCaseName('Add attributetype (edit schema file)')"> |
| | | <testcase name="getTestCaseName |
| | | ('Add attributetype (edit schema file)')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Add attributetype (edit schema file). Check schema replication when a new attributetype is added manually' |
| | | 'Replication: Schema Replication: Add attributetype (edit \ |
| | | schema file). Check schema replication when a new \ |
| | | attributetype is added manually' |
| | | </message> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | |
| | | <!-- Modify schema in "master" server --> |
| | | <call function="'copyFile'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : masterHost, |
| | | 'srcfile' : currentSchemaFile, |
| | | 'destfile' : provSchemaFile } |
| | | 'destfile' : provSchemaFile |
| | | } |
| | | </call> |
| | | <call function="'LdifModifyWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'sourceLdif' : provSchemaFile, |
| | | 'changesLdif' : '%s/replication/schemamods-1.ldif' % masterDataDir, |
| | | 'targetLdif' : currentSchemaFile } |
| | | 'changesLdif' : '%s/replication/schemamods-1.ldif' % \ |
| | | masterDataDir, |
| | | 'targetLdif' : currentSchemaFile |
| | | } |
| | | </call> |
| | | |
| | | <!-- Start the servers in the topology --> |
| | |
| | | |
| | | <call function="'Sleep'"> |
| | | { 'location' : masterHost, |
| | | 'sleepForMilliSeconds' : 1000 } |
| | | 'sleepForMilliSeconds' : 1000 |
| | | } |
| | | </call> |
| | | |
| | | <!-- Add entry to "consumer" server --> |
| | |
| | | 'dsInstancePort' : consumer.getPort(), |
| | | 'dsInstanceDn' : consumer.getRootDn(), |
| | | 'dsInstancePswd' : consumer.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-1.ldif' % clientDataDir } |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-1.ldif' % \ |
| | | clientDataDir |
| | | } |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers in |
| | | the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | | |
| | | <script> |
| | | knownIssue(2599) |
| | | </script> |
| | | |
| | | <call function="'testCase_Postamble'"/> |
| | | </sequence> |
| | | </testcase> |
| | |
| | | |
| | | <!-- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Delete objectclass (edit schema file) |
| | | #@TestName Replication: Schema Replication: Delete |
| | | objectclass (edit schema file) |
| | | #@TestID Delete objectclass (edit schema file) |
| | | #@TestPurpose Check schema replication when an objectclass is deleted manually |
| | | #@TestPurpose Check schema replication when an objectclass is |
| | | deleted manually |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestSteps Stop servers |
| | | #@TestSteps Edit 99-user.ldif to remove user-defined |
| | | objectclass definition on server1 |
| | | #@TestSteps Start servers |
| | | #@TestSteps Delete entry on server1 |
| | | #@TestSteps Add entry containing removed objectclass on |
| | | every server |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema remove replicated and last |
| | | entry add rejected on all servers (error 65: |
| | | objectclass violation) |
| | | --> |
| | | <testcase name="getTestCaseName('Delete objectclass (edit schema file)')"> |
| | | <testcase name="getTestCaseName |
| | | ('Delete objectclass (edit schema file)')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Delete objectclass (edit schema file). Check schema replication when an objectclass is deleted manually' |
| | | 'Replication: Schema Replication: Delete objectclass (edit \ |
| | | schema file). Check schema replication when an objectclass is \ |
| | | deleted manually' |
| | | </message> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | |
| | | <!-- Modify schema in "master" server --> |
| | | <call function="'copyFile'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : masterHost, |
| | | 'srcfile' : currentSchemaFile, |
| | | 'destfile' : provSchemaFile } |
| | | 'destfile' : provSchemaFile |
| | | } |
| | | </call> |
| | | <call function="'LdifModifyWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'sourceLdif' : provSchemaFile, |
| | | 'changesLdif' : '%s/replication/schemamods-2.ldif' % masterDataDir, |
| | | 'targetLdif' : currentSchemaFile } |
| | | 'changesLdif' : '%s/replication/schemamods-2.ldif' % \ |
| | | masterDataDir, |
| | | 'targetLdif' : currentSchemaFile |
| | | } |
| | | </call> |
| | | |
| | | <!-- Start the servers in the topology --> |
| | |
| | | |
| | | <call function="'Sleep'"> |
| | | { 'location' : masterHost, |
| | | 'sleepForMilliSeconds' : 1000 } |
| | | 'sleepForMilliSeconds' : 1000 |
| | | } |
| | | </call> |
| | | |
| | | <!-- Try to add entry to servers; should be rejected with error 65 (objectclass violation) --> |
| | | <!-- Try to add entry to servers; should be rejected with error 65 |
| | | (objectclass violation) --> |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-0.ldif' % clientDataDir, |
| | | 'expectedRC' : 65 } |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-0.ldif' % \ |
| | | clientDataDir, |
| | | 'expectedRC' : 65 |
| | | } |
| | | </call> |
| | | </iterate> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers in |
| | | the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | |
| | | |
| | | <!-- Test Case information |
| | | #@TestMarker Replication Schema Replication Tests |
| | | #@TestName Replication: Schema Replication: Modify objectclass (edit schema file) |
| | | #@TestName Replication: Schema Replication: Modify |
| | | objectclass (edit schema file) |
| | | #@TestID Modify objectclass (edit schema file) |
| | | #@TestPurpose Check schema replication when an objectclass is modified manually |
| | | #@TestPurpose Check schema replication when an objectclass is |
| | | modified manually |
| | | #@TestPreamble |
| | | #@TestSteps |
| | | #@TestSteps Stop servers |
| | | #@TestSteps Edit 99-user.ldif to modify user-defined |
| | | objectclass (make attributes MANDATORY) on |
| | | server1 |
| | | #@TestSteps Start servers |
| | | #@TestSteps Add entry containing newly added objectclass but |
| | | without required attributes on every server |
| | | #@TestPostamble |
| | | #@TestResult |
| | | #@TestResult Success if schema modify replicated and entry |
| | | add rejected with error 65 (objectclass |
| | | violation) on all servers |
| | | --> |
| | | <testcase name="getTestCaseName('Modify objectclass (edit schema file)')"> |
| | | <testcase name="getTestCaseName |
| | | ('Modify objectclass (edit schema file)')"> |
| | | <sequence> |
| | | <call function="'testCase_Preamble'"/> |
| | | <message> |
| | | 'Replication: Schema Replication: Modify objectclass (edit schema file). Check schema replication when an objectclass is modified manually' |
| | | 'Replication: Schema Replication: Modify objectclass (edit \ |
| | | schema file). Check schema replication when an objectclass is \ |
| | | modified manually' |
| | | </message> |
| | | |
| | | <!-- Stop the servers in the topology --> |
| | |
| | | <!-- Modify schema in "master" server --> |
| | | <call function="'copyFile'"> |
| | | { 'location' : masterHost, |
| | | 'remotehost' : masterHost, |
| | | 'srcfile' : currentSchemaFile, |
| | | 'destfile' : provSchemaFile } |
| | | 'destfile' : provSchemaFile |
| | | } |
| | | </call> |
| | | <call function="'LdifModifyWithScript'"> |
| | | { 'location' : masterHost, |
| | | 'dsPath' : masterPath, |
| | | 'sourceLdif' : provSchemaFile, |
| | | 'changesLdif' : '%s/replication/schemamods-3.ldif' % masterDataDir, |
| | | 'targetLdif' : currentSchemaFile } |
| | | 'changesLdif' : '%s/replication/schemamods-3.ldif' % \ |
| | | masterDataDir, |
| | | 'targetLdif' : currentSchemaFile |
| | | } |
| | | </call> |
| | | |
| | | <!-- Start the servers in the topology --> |
| | |
| | | |
| | | <call function="'Sleep'"> |
| | | { 'location' : masterHost, |
| | | 'sleepForMilliSeconds' : 1000 } |
| | | 'sleepForMilliSeconds' : 1000 |
| | | } |
| | | </call> |
| | | |
| | | <!-- Try to add entry to servers; should be rejected with error 65 (objectclass violation) --> |
| | | <!-- Try to add entry to servers; should be rejected with error 65 |
| | | (objectclass violation) --> |
| | | <iterate var="server" in="_topologyServerList"> |
| | | <call function="'addEntry'"> |
| | | { 'location' : clientHost, |
| | |
| | | 'dsInstancePort' : server.getPort(), |
| | | 'dsInstanceDn' : server.getRootDn(), |
| | | 'dsInstancePswd' : server.getRootPwd(), |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-2.ldif' % clientDataDir, |
| | | 'expectedRC' : 65 } |
| | | 'entryToBeAdded' : '%s/replication/newtestuser-2.ldif' % \ |
| | | clientDataDir, |
| | | 'expectedRC' : 65 |
| | | } |
| | | </call> |
| | | </iterate> |
| | | |
| | | <!-- Verify the synchronization of the schema among the servers in the topology --> |
| | | <!-- Verify the synchronization of the schema among the servers in |
| | | the topology --> |
| | | <call function="'verifySchemas'"> |
| | | [ clientHost, clientPath, master, consumerList, '99-user.ldif' ] |
| | | </call> |
| | | |
| | | <!-- Verify the synchronization of the trees among the servers in the topology --> |
| | | <!-- Verify the synchronization of the trees among the servers in |
| | | the topology --> |
| | | <call function="'verifyTrees'"> |
| | | [ clientHost, clientPath, master, consumerList, synchroSuffix ] |
| | | </call> |
| | |
| | | |
| | | |
| | | <import machine="STAF_LOCAL_HOSTNAME" |
| | | file="'%s/testcases/replication/replication_cleanup.xml' % (TESTS_DIR)"/> |
| | | file="'%s/testcases/replication/replication_cleanup.xml' % TESTS_DIR"/> |
| | | <call function="'replication_cleanup'" /> |
| | | |
| | | <call function="'testSuite_Postamble'"/> |