Merge from vscode 8e0f348413f4f616c23a88ae30030efa85811973 (#6381)

* Merge from vscode 8e0f348413f4f616c23a88ae30030efa85811973

* disable strict null check
This commit is contained in:
Anthony Dresser
2019-07-15 22:35:46 -07:00
committed by GitHub
parent f720ec642f
commit 0b7e7ddbf9
2406 changed files with 59140 additions and 35464 deletions

View File

@@ -4,7 +4,6 @@
*--------------------------------------------------------------------------------------------*/
import * as assert from 'assert';
import { KeyChord, KeyCode, KeyMod, Keybinding, ResolvedKeybinding, SimpleKeybinding, createKeybinding, createSimpleKeybinding } from 'vs/base/common/keyCodes';
import { IDisposable } from 'vs/base/common/lifecycle';
import { OS } from 'vs/base/common/platform';
import Severity from 'vs/base/common/severity';
import { ICommandService } from 'vs/platform/commands/common/commands';
@@ -14,9 +13,9 @@ import { IKeyboardEvent } from 'vs/platform/keybinding/common/keybinding';
import { KeybindingResolver } from 'vs/platform/keybinding/common/keybindingResolver';
import { ResolvedKeybindingItem } from 'vs/platform/keybinding/common/resolvedKeybindingItem';
import { USLayoutResolvedKeybinding } from 'vs/platform/keybinding/common/usLayoutResolvedKeybinding';
import { INotification, INotificationService, IPromptChoice, IPromptOptions, NoOpNotification } from 'vs/platform/notification/common/notification';
import { IStatusbarService } from 'vs/platform/statusbar/common/statusbar';
import { INotification, INotificationService, IPromptChoice, IPromptOptions, NoOpNotification, IStatusMessageOptions } from 'vs/platform/notification/common/notification';
import { NullTelemetryService } from 'vs/platform/telemetry/common/telemetryUtils';
import { ServiceIdentifier } from 'vs/platform/instantiation/common/instantiation';
function createContext(ctx: any) {
return {
@@ -35,10 +34,9 @@ suite('AbstractKeybindingService', () => {
resolver: KeybindingResolver,
contextKeyService: IContextKeyService,
commandService: ICommandService,
notificationService: INotificationService,
statusService?: IStatusbarService
notificationService: INotificationService
) {
super(contextKeyService, commandService, NullTelemetryService, notificationService, statusService);
super(contextKeyService, commandService, NullTelemetryService, notificationService);
this._resolver = resolver;
}
@@ -85,6 +83,10 @@ suite('AbstractKeybindingService', () => {
public _dumpDebugInfo(): string {
return '';
}
public _dumpDebugInfoJSON(): string {
return '';
}
}
let createTestKeybindingService: (items: ResolvedKeybindingItem[], contextValue?: any) => TestKeybindingService = null!;
@@ -129,7 +131,7 @@ suite('AbstractKeybindingService', () => {
};
let notificationService: INotificationService = {
_serviceBrand: undefined,
_serviceBrand: {} as ServiceIdentifier<INotificationService>,
notify: (notification: INotification) => {
showMessageCalls.push({ sev: notification.severity, message: notification.message });
return new NoOpNotification();
@@ -148,13 +150,8 @@ suite('AbstractKeybindingService', () => {
},
prompt(severity: Severity, message: string, choices: IPromptChoice[], options?: IPromptOptions) {
throw new Error('not implemented');
}
};
let statusbarService: IStatusbarService = {
_serviceBrand: undefined,
addEntry: undefined!,
setStatusMessage: (message: string, autoDisposeAfter?: number, delayBy?: number): IDisposable => {
},
status(message: string, options?: IStatusMessageOptions) {
statusMessageCalls!.push(message);
return {
dispose: () => {
@@ -166,7 +163,7 @@ suite('AbstractKeybindingService', () => {
let resolver = new KeybindingResolver(items, []);
return new TestKeybindingService(resolver, contextKeyService, commandService, notificationService, statusbarService);
return new TestKeybindingService(resolver, contextKeyService, commandService, notificationService);
};
});