Skip to content

Commit

Permalink
feat(#190): unify process_waits_in checks for single and multiple act…
Browse files Browse the repository at this point in the history
…ivityIds
  • Loading branch information
mmiikkkkaa committed Jun 7, 2023
1 parent 603e106 commit 0c26666
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,10 @@ class ProcessStage<SELF : ProcessStage<SELF, PROCESS_BEAN>, PROCESS_BEAN : Suppl
@As("process waits in activities $")
fun process_waits_in(@QuotedVarargs vararg activityId: String) = step {
require(activityId.isNotEmpty()) { "At least one activity id must be provided" }
activityId.map {
val job = job(it)
assertThat(job).`as`("Expecting the process to be waiting in activity '$it', but it was not.").isNotNull

val processInstance = processInstanceSupplier.get()
activityId.forEach {
assertThat(processInstance).isWaitingAt(it)
}
}

Expand Down

0 comments on commit 0c26666

Please sign in to comment.