Skip to content

Commit

Permalink
Add some logging to a flaky test (microsoft#12711)
Browse files Browse the repository at this point in the history
For #12690
Added some logging to see whats causing the tests to fail.
  • Loading branch information
Don Jayamanne committed Jul 2, 2020
1 parent 0962506 commit 08a0538
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/test/common/process/pythonDaemonPool.unit.test.ts
Expand Up @@ -20,6 +20,7 @@ import { IProcessLogger, IPythonExecutionService, Output } from '../../../client
import { sleep } from '../../../client/common/utils/async';
import { InterpreterInformation } from '../../../client/pythonEnvironments/info';
import { noop } from '../../core';
import { asyncDump } from '../asyncDump';
use(chaiPromised);

// tslint:disable: no-any max-func-body-length
Expand Down Expand Up @@ -48,7 +49,11 @@ suite('Daemon - Python Daemon Pool', () => {
listenStub.returns(undefined);
sendRequestStub.returns({ pong: 'hello' });
});
teardown(() => {
teardown(function () {
// tslint:disable-next-line: no-invalid-this
if (this.currentTest && this.currentTest.state === 'failed') {
asyncDump();
}
if (clock) {
clock.uninstall();
}
Expand Down

0 comments on commit 08a0538

Please sign in to comment.