mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-24 12:19:20 +00:00
Use correct casting when working with Object.freeze
Casting the result of Object.freeze results in a non-readonly object. Instead we should pass the type along to the call to `Object.freeze`
This commit is contained in:
@@ -14,7 +14,7 @@ const testDocumentUri = vscode.Uri.parse('untitled:test.ts');
|
||||
const insertModes = Object.freeze(['insert', 'replace']);
|
||||
|
||||
suite.skip('TypeScript Completions', () => {
|
||||
const configDefaults: VsCodeConfiguration = Object.freeze({
|
||||
const configDefaults = Object.freeze<VsCodeConfiguration>({
|
||||
[Config.autoClosingBrackets]: 'always',
|
||||
[Config.typescriptCompleteFunctionCalls]: false,
|
||||
[Config.insertMode]: 'insert',
|
||||
|
||||
@@ -14,7 +14,7 @@ const testDocumentUri = vscode.Uri.parse('untitled:test.ts');
|
||||
suite('JSDoc Completions', () => {
|
||||
const _disposables: vscode.Disposable[] = [];
|
||||
|
||||
const configDefaults: VsCodeConfiguration = Object.freeze({
|
||||
const configDefaults = Object.freeze<VsCodeConfiguration>({
|
||||
[Config.snippetSuggestions]: 'inline',
|
||||
});
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ namespace Config {
|
||||
}
|
||||
|
||||
suite('TypeScript References', () => {
|
||||
const configDefaults: VsCodeConfiguration = Object.freeze({
|
||||
const configDefaults = Object.freeze<VsCodeConfiguration>({
|
||||
[Config.referencesCodeLens]: true,
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user