Class AttributeTests
java.lang.Object
org.identityconnectors.contract.test.ContractTestBase
org.identityconnectors.contract.test.ObjectClassRunner
org.identityconnectors.contract.test.AttributeTests
Test that attributes satisfy contract.
Tests check:- non-readable attributes are not returnedByDefault
- attributes which are not returnedByDefault really are not returned unless specified in attrsToGet
- update of non-updateable attribute will fail
- required attributes must be creatable
- Author:
- David Adam
-
Field Summary
Fields inherited from class org.identityconnectors.contract.test.ContractTestBase
_connFacade, LOG_SEPARATOR
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionSet
<Class<? extends APIOperation>> Ask the subclasses for theAPIOperation
.Gets Test namevoid
testNonReadable
(ObjectClass objectClass) Non readable attributes should _not_ be returned by defaultvoid
testNonUpdateable
(ObjectClass objectClass) Update of non-updateable attribute is not acceptable.void
testRequirableIsCreatable
(ObjectClass objectClass) Required attributes must be creatable.void
testReturnedByDefault
(ObjectClass objectClass) Not returned by default attributes should not be returned, unless specified in attributesToGet (OperationOptions
)protected void
testRun
(ObjectClass objectClass) This method will be called configured number of timesMethods inherited from class org.identityconnectors.contract.test.ObjectClassRunner
getObjectClassInfo, getOperationOptionsByOp, getSchema, isObjectClassSupported, objectClasses, testContract
Methods inherited from class org.identityconnectors.contract.test.ContractTestBase
dispose, getConnectorFacade, getDataProvider, init
-
Constructor Details
-
AttributeTests
public AttributeTests()
-
-
Method Details
-
getAPIOperations
Description copied from class:ContractTestBase
Ask the subclasses for theAPIOperation
. Method returns set of required API operations that are prerequisites for running certain contract test.- Specified by:
getAPIOperations
in classContractTestBase
-
testRun
This method will be called configured number of times- Specified by:
testRun
in classObjectClassRunner
-
getTestName
Gets Test name- Specified by:
getTestName
in classObjectClassRunner
- Returns:
- Test Name
-
testNonReadable
@ParameterizedTest @MethodSource("objectClasses") public void testNonReadable(ObjectClass objectClass) Non readable attributes should _not_ be returned by default
API operations for acquiring attributes:
GetApiOp
-
testReturnedByDefault
@ParameterizedTest @MethodSource("objectClasses") public void testReturnedByDefault(ObjectClass objectClass) Not returned by default attributes should not be returned, unless specified in attributesToGet (
OperationOptions
)API operations for acquiring attributes:
-
testNonUpdateable
@ParameterizedTest @MethodSource("objectClasses") public void testNonUpdateable(ObjectClass objectClass) Update of non-updateable attribute is not acceptable. Connector should throw a RuntimeException.API operations for acquiring attributes:
GetApiOp
-
testRequirableIsCreatable
@ParameterizedTest @MethodSource("objectClasses") public void testRequirableIsCreatable(ObjectClass objectClass) Required attributes must be creatable. It is a fialure if a required attribute is not creatable.
-