use of com.evolveum.midpoint.schema.GetOperationOptions in project midpoint by Evolveum.
the class AbstractManualResourceTest method test109GetAccountWillFutureNoFetch.
@Test
public void test109GetAccountWillFutureNoFetch() throws Exception {
final String TEST_NAME = "test109GetAccountWillFutureNoFetch";
displayTestTile(TEST_NAME);
// GIVEN
Task task = createTask(TEST_NAME);
OperationResult result = task.getResult();
GetOperationOptions options = GetOperationOptions.createPointInTimeType(PointInTimeType.FUTURE);
options.setNoFetch(true);
// WHEN
displayWhen(TEST_NAME);
PrismObject<ShadowType> shadowProvisioningFuture = provisioningService.getObject(ShadowType.class, ACCOUNT_WILL_OID, SelectorOptions.createCollection(options), task, result);
// THEN
displayThen(TEST_NAME);
assertSuccess(result);
display("Provisioning shadow (future,noFetch)", shadowProvisioningFuture);
assertNotNull("no OID", shadowProvisioningFuture.getOid());
ShadowType shadowTypeProvisioning = shadowProvisioningFuture.asObjectable();
assertShadowName(shadowProvisioningFuture, ACCOUNT_WILL_USERNAME);
assertEquals("Wrong kind (provisioning)", ShadowKindType.ACCOUNT, shadowTypeProvisioning.getKind());
assertAttribute(shadowProvisioningFuture, ATTR_USERNAME_QNAME, ACCOUNT_WILL_USERNAME);
assertAttributeFromCache(shadowProvisioningFuture, ATTR_FULLNAME_QNAME, ACCOUNT_WILL_FULLNAME);
assertNoAttribute(shadowProvisioningFuture, ATTR_DESCRIPTION_QNAME);
assertShadowActivationAdministrativeStatusFromCache(shadowProvisioningFuture, ActivationStatusType.ENABLED);
assertShadowExists(shadowProvisioningFuture, true);
// TODO
// assertShadowPassword(shadowProvisioningFuture);
}
use of com.evolveum.midpoint.schema.GetOperationOptions in project midpoint by Evolveum.
the class AbstractManualResourceTest method test303GetAccountWillFutureNoFetch.
@Test
public void test303GetAccountWillFutureNoFetch() throws Exception {
final String TEST_NAME = "test303GetAccountWillFutureNoFetch";
displayTestTile(TEST_NAME);
// GIVEN
Task task = createTask(TEST_NAME);
OperationResult result = task.getResult();
GetOperationOptions options = GetOperationOptions.createPointInTimeType(PointInTimeType.FUTURE);
options.setNoFetch(true);
// WHEN
displayWhen(TEST_NAME);
PrismObject<ShadowType> shadowProvisioningFuture = provisioningService.getObject(ShadowType.class, ACCOUNT_WILL_OID, SelectorOptions.createCollection(options), task, result);
// THEN
displayThen(TEST_NAME);
assertSuccess(result);
display("Provisioning shadow (future,noFetch)", shadowProvisioningFuture);
assertNotNull("no OID", shadowProvisioningFuture.getOid());
assertShadowName(shadowProvisioningFuture, ACCOUNT_WILL_USERNAME);
assertShadowDead(shadowProvisioningFuture);
assertNoShadowPassword(shadowProvisioningFuture);
}
Aggregations