[
https://issues.apache.org/jira/browse/DIRSERVER-1398?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Emmanuel Lecharny updated DIRSERVER-1398:
-----------------------------------------
Fix Version/s: (was: 1.5.5)
2.0.0-RC1
Postponed to 2.0.0-RC1
> Add tests for modify Operation
> ------------------------------
>
> Key: DIRSERVER-1398
> URL: https://issues.apache.org/jira/browse/DIRSERVER-1398
> Project: Directory ApacheDS
> Issue Type: Task
> Affects Versions: 1.5.4
> Reporter: Emmanuel Lecharny
> Fix For: 2.0.0-RC1
>
>
> We need more test coverage for the modify operation. I have written 30 unit
> tests for the add and remove changes, and discovered 3 bugs in the server.
> Here are the missing tests (a * in front of the test means it's already
> implemented) :
> - add change :
> 1) Entry exists
> * 1.1) AT does not exist in entry
> * - new valid AVA, new AT is in MAY :OK1
> * - new valid AVA, new AT is not in MAY => error : OK
> * - new valid AVA, new AT is not in MAY, but OC contains extensibleOC :OK
> * - new valid AVA, new AT is not in MAY, but OC contains extensibleOC,
> legal empty value :OK
> * - new invalid AVA, not existing AT => error :OK
> * - new invalid AVA, existing AT, two values in a single valued AT => error
> :OK
> * - new invalid AVA, not existing AT, extensibleObject in OCs => error :OK
> * - new invalid AVA (Value is invalid per syntax), AT is in MAY => error :OK
> * - new invalid AVA (Value is invalid per syntax), AT is not in MAY, but OC
> contains extensibleOC => error :OK
> * - new OperationalAttribute => error :OK
> * - new OperationalAttribute, OC contains extensibleOC => error :OK
> 1.2) AT exists
> * - new valid Value, not existing, AT is multiValued : OK
> * - new valid Value, existing, AT is multiValued => error ???
> * - new empty valid Value, existing, AT is multiValued
> * - new valid Value, AT is singleValued => error
> * - new valid Value, existing, AT is singleValued
> * - new invalid Value => error
> 1.3) Entry is an alias
> TODO : define the tests
> 1.4) Entry is a referral
> TODO : define the tests
> 1.5) Entry is a schema entry
> TODO : define the tests
> 1.6) The added AT is an ObjectClass
> TODO : define the tests
>
> * 2) Entry does not exists => error
> 3) User does not have enough rights
> TODO : define the tests
> Delete change :
> 1) Entry exists
> 1.1) The AT exists
> * - The Value exists, it's not part of the RDN, the AT is not singleValued,
> there are other values
> * - The Values exist, they are not part of the RDN, the AT is not
> singleValued, all the values will be removed
> * - The Value exists, it's not part of the RDN, this is the unique value,
> it's part of MUST => error
> * - The Value exists, it's not part of the RDN, the AT is singleValued, the
> AT is not in MUST
> * - The Value exists, it's not part of the RDN, the AT is singleValued, the
> AT is in MUST => error
> * - The Value exists, it's part of the RDN => error
> * - The AVA has no value, it's not part of the RDN, it's not part of MUST
> * - The AVA has no value, it's not part of the RDN, it's part of MUST =>
> error
> * - The AVA has no value, it's part of the RDN => error
> * - The Value does not exists => error
> 1.2) The AT does not exist
> * - The AT does not exists, and is not part of MAY/MUST => error
> * - The AT does not exists, and is part of MAY/MUST => error
> 1.3) Entry is an alias
> TODO : define the tests
> 1.4) Entry is a referral
> TODO : define the tests
> 1.5) Entry is a schema entry
> TODO : define the tests
> 1.6) The deleted AT is an ObjectClass
> TODO : define the tests
>
> * 2) Entry does not exist => error
> 3) user does not have enough rights
> TODO : define the tests
> Replace change :
> 1) Entry exists
> 1.1) The AT exists
> TODO : define the tests
> 1.2) The AT does not exist
> TODO : define the tests
> 1.3) Entry is an alias
> TODO : define the tests
> 1.4) Entry is a referral
> TODO : define the tests
> 1.5) Entry is a schema entry
> TODO : define the tests
> 1.6) The deleted AT is an ObjectClass
> TODO : define the tests
> 2) Entry does not exist => error
> TODO : define the tests
> 3) user does not have enough rights
> TODO : define the tests
> Multiple operations :
> Typically, such as :
> Add X,x ..., Del X,x (null operation)
> Del X,y ..., Add X,z (replace [X, y->z])
> Del X,x ..., Del X,x (double delete, should ignore the second deletion)
>
> Add ... Add
> Add ... Del
> Add ... Replace
> Del ... Del
> Del ... Add
> Del ... Replace
> Replace ... Replace
> Replace ... Add
> Replace ... Del
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.