Skip to content

Commit

Permalink
merge: #12721
Browse files Browse the repository at this point in the history
12721: [Backport stable/8.0] Fix flaky `EmbeddedSubProcessTest` r=remcowesterhoud a=remcowesterhoud

# Description
Backport of #12697 to `stable/8.0`.

relates to #11844

Co-authored-by: Remco Westerhoud <remco@westerhoud.nl>
  • Loading branch information
zeebe-bors-camunda[bot] and remcowesterhoud committed May 10, 2023
2 parents f7e19f5 + 303e38e commit 4494294
Showing 1 changed file with 10 additions and 4 deletions.
Expand Up @@ -24,6 +24,7 @@
import io.camunda.zeebe.protocol.record.ValueType;
import io.camunda.zeebe.protocol.record.intent.JobIntent;
import io.camunda.zeebe.protocol.record.intent.MessageIntent;
import io.camunda.zeebe.protocol.record.intent.MessageSubscriptionIntent;
import io.camunda.zeebe.protocol.record.intent.ProcessEventIntent;
import io.camunda.zeebe.protocol.record.intent.ProcessInstanceIntent;
import io.camunda.zeebe.protocol.record.intent.VariableIntent;
Expand Down Expand Up @@ -623,10 +624,15 @@ public void shouldNotTriggerBoundaryEventWhenFlowscopeIsInterrupted() {
.withVariable("correlationKey", "correlationKey")
.create();

RecordingExporter.processInstanceRecords(ProcessInstanceIntent.ELEMENT_ACTIVATED)
.withProcessInstanceKey(processInstanceKey)
.withElementId("task")
.await();
assertThat(
RecordingExporter.messageSubscriptionRecords(MessageSubscriptionIntent.CREATED)
.withProcessInstanceKey(processInstanceKey)
.limit(2))
.describedAs(
"The 2 message subscriptions must be created before we publish the "
+ "messages. As the messages have a TTL of 0 seconds")
.describedAs("")
.hasSize(2);

// when
// We need to make sure no records are written in between the publish commands. This could
Expand Down

0 comments on commit 4494294

Please sign in to comment.