KOs from implemented SessionAssert class ignored by .exitBlockOnFail() and .exitHereIfFailed

Hi,

Per recommendations from another thread, I’ve mocked a session assert with the following…

`

DataWriter.dispatch(
new RequestMessage(
scenario = session.scenarioName,
userId = session.userId,
groupHierarchy = session.groupHierarchy,
name = assertName,
requestStartDate = now,
requestEndDate = now,
responseStartDate = now,
responseEndDate = now,
status = if(assertTrue) OK else KO,
message = Option(assertMessage),
extraInfo = List()))

`

It works well reporting KO=1 on session failures and OK=1 on passes. The problem seems to be that on sessions failures, when KO=1 is reported, the simulation does not actually exit immediately when the scn or .exec() is wrapped in .exitBlockOnFail() and .exitHereIfFailed respectively. The failure gets reported and then the simulation continues running until the end is reached. What can I do to get the scn to exit immediately on session asserts?

Example…

`

//If the session assert fails, then the following .exec should not get executed, but it does for me

val scn = scenario(“This test should exit immediately on failure”)
.exitBlockOnFail(
exec(session => {
something…

new SessionAssert(Session, isTrue, “AssertionName”, “AssertionMessage”)

session
})
.exec(…)

)

`

Thanks,
Christian

Any help here? Is this a bug? Is there anything I can set that will force these failed asserts to stop the simulation on fail?

Thanks,
Christian