Skip to content

Commit

Permalink
PP-456 CucumberJS Reporter concurrent run check issue
Browse files Browse the repository at this point in the history
  • Loading branch information
iiojib committed Oct 31, 2023
1 parent f88121c commit 63df885
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion qase-cucumberjs/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,8 @@ class QaseReporter extends Formatter {
private scenarios: Record<string, string> = {};
private uploadsInQueueCount = 0;

private checkOperation: Promise<unknown> | null = null

Check failure on line 151 in qase-cucumberjs/src/index.ts

View workflow job for this annotation

GitHub Actions / Project qase-cucumberjs - Node 14

Missing semicolon

public constructor(options: IFormatterOptions) {
super(options);
this.config = prepareConfig(options.parsedArgvOptions as Config, options.parsedArgvOptions?.qaseConfig);
Expand Down Expand Up @@ -181,7 +183,7 @@ class QaseReporter extends Formatter {
} else if (envelope.attachment) {
void this.upload(envelope.attachment);
} else if (envelope.testRunStarted) {
void this.checkProject(
this.checkOperation = this.checkProject(
this.config.projectCode,
async (prjExists): Promise<void> => {
if (prjExists) {
Expand Down Expand Up @@ -325,6 +327,7 @@ class QaseReporter extends Formatter {
}

private async publishResults() {
await this.checkOperation;
await this.waitUploads();

const res: ResultCreate[] = [];
Expand Down

0 comments on commit 63df885

Please sign in to comment.