Skip to content

Commit ede011f

Browse files
committed
Update format tests to restart LSP after setting options
1 parent a8644a7 commit ede011f

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

.vscode/launch.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"preLaunchTask": "buildDev"
1313
},
1414
{
15-
"name": "[Roslyn] Launch Current File Integration Tests",
15+
"name": "[Roslyn] Run Current File Integration Tests",
1616
"type": "extensionHost",
1717
"request": "launch",
1818
"runtimeExecutable": "${execPath}",

test/lsptoolshost/integrationTests/formatting.integration.test.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,16 +12,14 @@ import {
1212
expectText,
1313
openFileInWorkspaceAsync,
1414
} from './integrationHelpers';
15-
import { describe, beforeAll, beforeEach, afterAll, test, afterEach } from '@jest/globals';
15+
import { describe, beforeEach, afterAll, test, afterEach } from '@jest/globals';
1616
import { formatDocumentAsync, formatOnTypeAsync, formatRangeAsync } from './formattingTestHelpers';
1717

1818
describe(`Formatting Tests`, () => {
19-
beforeAll(async () => {
20-
await activateCSharpExtension();
21-
});
22-
2319
beforeEach(async () => {
2420
await setOrganizeImportsOnFormat(undefined);
21+
await activateCSharpExtension();
22+
2523
await openFileInWorkspaceAsync(path.join('src', 'app', 'Formatting.cs'));
2624
});
2725

0 commit comments

Comments
 (0)