diff --git a/src/host/main.js b/src/host/main.js index e541640..2eda10e 100644 --- a/src/host/main.js +++ b/src/host/main.js @@ -101,7 +101,7 @@ export async function hostMain(options) { }; const perTestUrl = callbackUrl.replace( ':testRowNumber', - body.presentationNumber ?? body.testCsvRow + body?.presentationNumber ?? body?.testCsvRow ?? '' ); lastCallbackRequest = lastCallbackRequest.then(() => options @@ -114,6 +114,8 @@ export async function hostMain(options) { ); }; + postCallbackWhenEnabled({ status: 'PLAN_RUNNING' }); + for (const test of plan.tests) { const file = plan.files.find(({ name }) => name === test.filepath); const testSource = JSON.parse(textDecoder.decode(file.bufferData)); @@ -165,6 +167,7 @@ export async function hostMain(options) { stopDrivers(); await emitPlanResults(plan); + postCallbackWhenEnabled({ status: 'PLAN_COMPLETED' }); } log(HostMessage.STOP_SERVER);