diff --git a/src/reporters/tapFormatTransform.ts b/src/reporters/tapFormatTransform.ts index ffa69490..70c67447 100644 --- a/src/reporters/tapFormatTransform.ts +++ b/src/reporters/tapFormatTransform.ts @@ -37,13 +37,14 @@ export class TapFormatTransformer extends Readable { } _read(): void { + this.logger.trace('starting format'); this.format(); this.push(null); // Signal the end of the stream + this.logger.trace('finishing format'); } @elapsedTime() public format(): void { - this.logger.trace('starting format'); const testPointCount = this.testResult.tests.length; this.push(`1..${testPointCount}\n`); @@ -52,7 +53,6 @@ export class TapFormatTransformer extends Readable { this.epilogue?.forEach((c) => { this.push(`# ${c}\n`); }); - this.logger.trace('finishing format'); } @elapsedTime() diff --git a/src/streaming/testResultStringifyStream.ts b/src/streaming/testResultStringifyStream.ts index ca9e81ea..bd13c260 100644 --- a/src/streaming/testResultStringifyStream.ts +++ b/src/streaming/testResultStringifyStream.ts @@ -23,13 +23,14 @@ export class TestResultStringifyStream extends Readable { } _read(): void { + this.logger.trace('starting format'); this.format(); this.push(null); // Signal the end of the stream + this.logger.trace('finishing format'); } @elapsedTime() public format(): void { - this.logger.trace('starting format'); const { summary } = this.testResult; // strip out vars not included in the summary data reported to the user @@ -43,7 +44,6 @@ export class TestResultStringifyStream extends Readable { // closing outer curly this.push(`}`); - this.logger.trace('finishing format'); } @elapsedTime()