Skip to content

Commit

Permalink
merge: #9464
Browse files Browse the repository at this point in the history
9464: [Backport 8.0] Create test cases for nullable variable value r=saig0 a=aivinog1

## Description

Just a backport for #9384

## Related issues

<!-- Which issues are closed by this PR or are related -->

#9382



Co-authored-by: Alexey Vinogradov <vinogradov.a.i.93@gmail.com>
  • Loading branch information
zeebe-bors-camunda[bot] and aivinog1 committed Jun 1, 2022
2 parents 06e2b77 + 796edd2 commit 21fbfa2
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
Expand Up @@ -441,6 +441,18 @@ final var record = new DeploymentDistributionRecord();
"{'type':'','processDefinitionVersion':-1,'elementId':'','bpmnProcessId':'','processDefinitionKey':-1,'processInstanceKey':-1,'elementInstanceKey':-1,'variables':{},'worker':'','retries':-1,'retryBackoff':0,'recurringTime':-1,'errorMessage':'','errorCode':'','customHeaders':{},'deadline':-1}"
},
/////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////// JobRecord with nullable variable //////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////
{
"JobRecordWithNullableVariable",
(Supplier<UnifiedRecordValue>)
() ->
new JobRecord()
.setVariables(
new UnsafeBuffer(MsgPackConverter.convertToMsgPack("{'foo':null}"))),
"{'type':'','errorMessage':'','bpmnProcessId':'','processDefinitionKey':-1,'processInstanceKey':-1,'elementId':'','elementInstanceKey':-1,'variables':{'foo':null},'deadline':-1,'worker':'','retries':-1,'retryBackoff':0,'recurringTime':-1,'errorCode':'','processDefinitionVersion':-1,'customHeaders':{}}"
},
/////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////// MessageRecord /////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////
{
Expand Down
Expand Up @@ -59,6 +59,7 @@ public static void performSampleWorkload(final ZeebeClient client) {
variables.put("orderId", "foo-bar-123");
variables.put("largeValue", "x".repeat(8192));
variables.put("unicode", "Á");
variables.put("nullable", null);

final long processInstanceKey =
client
Expand Down

0 comments on commit 21fbfa2

Please sign in to comment.