Skip to content

Commit dde577b

Browse files
committed
activate git before smoke tests
1 parent e297e74 commit dde577b

4 files changed

Lines changed: 3 additions & 17 deletions

File tree

extensions/git/package.json

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,6 @@
2626
},
2727
"contributes": {
2828
"commands": [
29-
{
30-
"command": "git.activate",
31-
"title": "%command.activate%",
32-
"category": "Git"
33-
},
3429
{
3530
"command": "git.setLogLevel",
3631
"title": "%command.setLogLevel%",
@@ -456,10 +451,6 @@
456451
],
457452
"menus": {
458453
"commandPalette": [
459-
{
460-
"command": "git.activate",
461-
"when": "false"
462-
},
463454
{
464455
"command": "git.clone",
465456
"when": "config.git.enabled"

extensions/git/package.nls.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"displayName": "Git",
33
"description": "Git SCM Integration",
4-
"command.activate": "Activate",
54
"command.setLogLevel": "Set Log Level...",
65
"command.clone": "Clone",
76
"command.init": "Initialize Repository",

extensions/git/src/commands.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -253,11 +253,6 @@ export class CommandCenter {
253253
});
254254
}
255255

256-
@command('git.activate')
257-
async activate(): Promise<void> {
258-
// noop
259-
}
260-
261256
@command('git.setLogLevel')
262257
async setLogLevel(): Promise<void> {
263258
const createItem = (logLevel: LogLevel) => ({

extensions/git/src/test/smoke.test.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,9 @@ suite('git smoke test', function () {
4949
cp.execSync('git commit -m "initial commit"', { cwd });
5050

5151
// make sure git is activated
52-
await commands.executeCommand('git.activate');
53-
git = extensions.getExtension<GitExtension>('vscode.git')!.exports.getAPI(1);
52+
const ext = extensions.getExtension<GitExtension>('vscode.git');
53+
await ext?.activate();
54+
git = ext!.exports.getAPI(1);
5455

5556
if (git.repositories.length === 0) {
5657
await eventToPromise(git.onDidOpenRepository);

0 commit comments

Comments
 (0)