Fix strict null type errors in tests
parent
4743190f77
commit
18d2ff160c
|
@ -142,6 +142,7 @@
|
|||
"./vs/base/test/common/marshalling.test.ts",
|
||||
"./vs/base/test/common/mime.test.ts",
|
||||
"./vs/base/test/common/objects.test.ts",
|
||||
"./vs/base/test/common/octicon.test.ts",
|
||||
"./vs/base/test/common/paging.test.ts",
|
||||
"./vs/base/test/common/paths.test.ts",
|
||||
"./vs/base/test/common/resources.test.ts",
|
||||
|
@ -214,6 +215,7 @@
|
|||
"./vs/editor/contrib/comment/comment.ts",
|
||||
"./vs/editor/contrib/comment/lineCommentCommand.ts",
|
||||
"./vs/editor/contrib/comment/test/blockCommentCommand.test.ts",
|
||||
"./vs/editor/contrib/comment/test/lineCommentCommand.test.ts",
|
||||
"./vs/editor/contrib/contextmenu/contextmenu.ts",
|
||||
"./vs/editor/contrib/cursorUndo/cursorUndo.ts",
|
||||
"./vs/editor/contrib/dnd/dnd.ts",
|
||||
|
|
|
@ -8,7 +8,7 @@ import { matchesFuzzyOcticonAware, parseOcticons } from 'vs/base/common/octicon'
|
|||
|
||||
export interface IOcticonFilter {
|
||||
// Returns null if word doesn't match.
|
||||
(query: string, target: { text: string, octiconOffsets?: number[] }): IMatch[];
|
||||
(query: string, target: { text: string, octiconOffsets?: number[] }): IMatch[] | null;
|
||||
}
|
||||
|
||||
function filterOk(filter: IOcticonFilter, word: string, target: { text: string, octiconOffsets?: number[] }, highlights?: { start: number; end: number; }[]) {
|
||||
|
|
|
@ -950,7 +950,9 @@ suite('Editor Contrib - Line Comment in mixed modes', () => {
|
|||
|
||||
this._register(modes.TokenizationRegistry.register(this.getLanguageIdentifier().language, {
|
||||
getInitialState: (): modes.IState => NULL_STATE,
|
||||
tokenize: undefined,
|
||||
tokenize: () => {
|
||||
throw new Error('not implemented');
|
||||
},
|
||||
tokenize2: (line: string, state: modes.IState): TokenizationResult2 => {
|
||||
let languageId = (/^ /.test(line) ? INNER_LANGUAGE_ID : OUTER_LANGUAGE_ID);
|
||||
|
||||
|
|
Loading…
Reference in New Issue