use of org.camunda.bpm.engine.variable.value.TypedValue in project camunda-bpm-platform by camunda.
the class ProcessInstanceAuthorizationTest method testGetVariableLocalTypedWithReadPermissionOnProcessInstance.
public void testGetVariableLocalTypedWithReadPermissionOnProcessInstance() {
// given
String processInstanceId = startProcessInstanceByKey(PROCESS_KEY, getVariables()).getId();
createGrantAuthorization(PROCESS_INSTANCE, processInstanceId, userId, READ);
// when
TypedValue typedValue = runtimeService.getVariableLocalTyped(processInstanceId, VARIABLE_NAME);
// then
assertNotNull(typedValue);
assertEquals(VARIABLE_VALUE, typedValue.getValue());
}
use of org.camunda.bpm.engine.variable.value.TypedValue in project camunda-bpm-platform by camunda.
the class ProcessInstanceAuthorizationTest method testGetVariableLocalTypedWithReadPermissionOnAnyProcessInstance.
public void testGetVariableLocalTypedWithReadPermissionOnAnyProcessInstance() {
// given
String processInstanceId = startProcessInstanceByKey(PROCESS_KEY, getVariables()).getId();
createGrantAuthorization(PROCESS_INSTANCE, ANY, userId, READ);
// when
TypedValue typedValue = runtimeService.getVariableLocalTyped(processInstanceId, VARIABLE_NAME);
// then
assertNotNull(typedValue);
assertEquals(VARIABLE_VALUE, typedValue.getValue());
}
use of org.camunda.bpm.engine.variable.value.TypedValue in project camunda-bpm-platform by camunda.
the class ProcessInstanceAuthorizationTest method testGetVariableTypedWithReadInstancePermissionOnAnyProcessDefinition.
public void testGetVariableTypedWithReadInstancePermissionOnAnyProcessDefinition() {
// given
String processInstanceId = startProcessInstanceByKey(PROCESS_KEY, getVariables()).getId();
createGrantAuthorization(PROCESS_DEFINITION, ANY, userId, READ_INSTANCE);
// when
TypedValue typedValue = runtimeService.getVariableTyped(processInstanceId, VARIABLE_NAME);
// then
assertNotNull(typedValue);
assertEquals(VARIABLE_VALUE, typedValue.getValue());
}
use of org.camunda.bpm.engine.variable.value.TypedValue in project camunda-bpm-platform by camunda.
the class ProcessInstanceAuthorizationTest method testGetVariableLocalTypedWithReadInstancePermissionOnProcessDefinition.
public void testGetVariableLocalTypedWithReadInstancePermissionOnProcessDefinition() {
// given
String processInstanceId = startProcessInstanceByKey(PROCESS_KEY, getVariables()).getId();
createGrantAuthorization(PROCESS_DEFINITION, PROCESS_KEY, userId, READ_INSTANCE);
// when
TypedValue typedValue = runtimeService.getVariableLocalTyped(processInstanceId, VARIABLE_NAME);
// then
assertNotNull(typedValue);
assertEquals(VARIABLE_VALUE, typedValue.getValue());
}
use of org.camunda.bpm.engine.variable.value.TypedValue in project camunda-bpm-platform by camunda.
the class ProcessInstanceAuthorizationTest method testGetVariableTypedWithReadPermissionOnAnyProcessInstance.
public void testGetVariableTypedWithReadPermissionOnAnyProcessInstance() {
// given
String processInstanceId = startProcessInstanceByKey(PROCESS_KEY, getVariables()).getId();
createGrantAuthorization(PROCESS_INSTANCE, ANY, userId, READ);
// when
TypedValue typedValue = runtimeService.getVariableTyped(processInstanceId, VARIABLE_NAME);
// then
assertNotNull(typedValue);
assertEquals(VARIABLE_VALUE, typedValue.getValue());
}
Aggregations