mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-25 02:58:56 +01:00
testing: polish up test output terminal handling
Fixes https://github.com/microsoft/vscode/issues/119642
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
import { bufferToStream, VSBuffer } from 'vs/base/common/buffer';
|
||||
import { CancellationToken } from 'vs/base/common/cancellation';
|
||||
import { Disposable, IDisposable } from 'vs/base/common/lifecycle';
|
||||
import { emptyStream } from 'vs/base/common/stream';
|
||||
import { isDefined } from 'vs/base/common/types';
|
||||
import { URI, UriComponents } from 'vs/base/common/uri';
|
||||
import { Range } from 'vs/editor/common/core/range';
|
||||
@@ -72,8 +73,15 @@ export class MainThreadTesting extends Disposable implements MainThreadTestingSh
|
||||
* @inheritdoc
|
||||
*/
|
||||
public $publishExtensionProvidedResults(results: ISerializedTestResults, persist: boolean): void {
|
||||
// todo
|
||||
this.resultService.push(new HydratedTestResult(results, () => Promise.resolve(bufferToStream(VSBuffer.alloc(0))), persist));
|
||||
this.resultService.push(new HydratedTestResult(
|
||||
results,
|
||||
() => Promise.resolve(
|
||||
results.output
|
||||
? bufferToStream(VSBuffer.fromString(results.output))
|
||||
: emptyStream(),
|
||||
),
|
||||
persist,
|
||||
));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user