Show the channel on download start (#2178)
This commit is contained in:
Родитель
9523d3b5cb
Коммит
12ce332305
|
@ -4,12 +4,12 @@
|
||||||
*--------------------------------------------------------------------------------------------*/
|
*--------------------------------------------------------------------------------------------*/
|
||||||
|
|
||||||
import { BaseChannelObserver } from "./BaseChannelObserver";
|
import { BaseChannelObserver } from "./BaseChannelObserver";
|
||||||
import { BaseEvent, PackageInstallation, InstallationFailure, DebuggerNotInstalledFailure, DebuggerPrerequisiteFailure, ProjectJsonDeprecatedWarning } from "../omnisharp/loggingEvents";
|
import { BaseEvent, InstallationFailure, DebuggerNotInstalledFailure, DebuggerPrerequisiteFailure, ProjectJsonDeprecatedWarning, DownloadStart } from "../omnisharp/loggingEvents";
|
||||||
|
|
||||||
export class CsharpChannelObserver extends BaseChannelObserver {
|
export class CsharpChannelObserver extends BaseChannelObserver {
|
||||||
public post = (event: BaseEvent) => {
|
public post = (event: BaseEvent) => {
|
||||||
switch (event.constructor.name) {
|
switch (event.constructor.name) {
|
||||||
case PackageInstallation.name:
|
case DownloadStart.name:
|
||||||
case InstallationFailure.name:
|
case InstallationFailure.name:
|
||||||
case DebuggerNotInstalledFailure.name:
|
case DebuggerNotInstalledFailure.name:
|
||||||
case DebuggerPrerequisiteFailure.name:
|
case DebuggerPrerequisiteFailure.name:
|
||||||
|
|
|
@ -6,13 +6,13 @@
|
||||||
import { should, expect } from 'chai';
|
import { should, expect } from 'chai';
|
||||||
import { getNullChannel } from '../testAssets/Fakes';
|
import { getNullChannel } from '../testAssets/Fakes';
|
||||||
import { CsharpChannelObserver } from '../../../src/observers/CsharpChannelObserver';
|
import { CsharpChannelObserver } from '../../../src/observers/CsharpChannelObserver';
|
||||||
import { InstallationFailure, PackageInstallation, DebuggerNotInstalledFailure, DebuggerPrerequisiteFailure, ProjectJsonDeprecatedWarning, BaseEvent } from '../../../src/omnisharp/loggingEvents';
|
import { InstallationFailure, DebuggerNotInstalledFailure, DebuggerPrerequisiteFailure, ProjectJsonDeprecatedWarning, BaseEvent, DownloadStart } from '../../../src/omnisharp/loggingEvents';
|
||||||
|
|
||||||
suite("CsharpChannelObserver", () => {
|
suite("CsharpChannelObserver", () => {
|
||||||
suiteSetup(() => should());
|
suiteSetup(() => should());
|
||||||
[
|
[
|
||||||
new InstallationFailure("someStage", "someError"),
|
new InstallationFailure("someStage", "someError"),
|
||||||
new PackageInstallation("somePackage"),
|
new DownloadStart("somePackage"),
|
||||||
new DebuggerNotInstalledFailure(),
|
new DebuggerNotInstalledFailure(),
|
||||||
new DebuggerPrerequisiteFailure("some failure"),
|
new DebuggerPrerequisiteFailure("some failure"),
|
||||||
new ProjectJsonDeprecatedWarning()
|
new ProjectJsonDeprecatedWarning()
|
||||||
|
|
Загрузка…
Ссылка в новой задаче