Skip to content

Commit ae2e429

Browse files
authored
Merge pull request #270 from RooVetGit/feat/full_Integration_Tests
Set up vscode integration test
2 parents 6beb90e + 8e54360 commit ae2e429

File tree

8 files changed

+403
-16
lines changed

8 files changed

+403
-16
lines changed

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,6 @@ roo-cline-*.vsix
1111

1212
# Local prompts and rules
1313
/local-prompts
14+
15+
# Test environment
16+
.test_env

.vscode-test.mjs

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,14 @@
1-
import { defineConfig } from "@vscode/test-cli"
1+
import { defineConfig } from '@vscode/test-cli';
22

33
export default defineConfig({
4-
files: "out/test/**/*.test.js",
5-
})
4+
files: 'src/test/extension.test.ts',
5+
workspaceFolder: '.',
6+
mocha: {
7+
timeout: 60000,
8+
ui: 'tdd'
9+
},
10+
launchArgs: [
11+
'--enable-proposed-api=RooVeterinaryInc.roo-cline',
12+
'--disable-extensions'
13+
]
14+
});

package-lock.json

Lines changed: 14 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
"url": "https://github.com/RooVetGit/Roo-Cline"
2121
},
2222
"homepage": "https://github.com/RooVetGit/Roo-Cline",
23+
"enabledApiProposals": [
24+
"extensionRuntime"
25+
],
2326
"categories": [
2427
"AI",
2528
"Chat",
@@ -159,6 +162,7 @@
159162
"start:webview": "cd webview-ui && npm run start",
160163
"test": "jest && npm run test:webview",
161164
"test:webview": "cd webview-ui && npm run test",
165+
"test:extension": "vscode-test",
162166
"prepare": "husky",
163167
"publish:marketplace": "vsce publish",
164168
"publish": "npm run build && changeset publish && npm install --package-lock-only",
@@ -181,6 +185,7 @@
181185
"@typescript-eslint/parser": "^7.11.0",
182186
"@vscode/test-cli": "^0.0.9",
183187
"@vscode/test-electron": "^2.4.0",
188+
"dotenv": "^16.4.7",
184189
"esbuild": "^0.24.0",
185190
"eslint": "^8.57.0",
186191
"husky": "^9.1.7",
@@ -192,9 +197,9 @@
192197
},
193198
"dependencies": {
194199
"@anthropic-ai/bedrock-sdk": "^0.10.2",
195-
"@aws-sdk/client-bedrock-runtime": "^3.706.0",
196200
"@anthropic-ai/sdk": "^0.26.0",
197201
"@anthropic-ai/vertex-sdk": "^0.4.1",
202+
"@aws-sdk/client-bedrock-runtime": "^3.706.0",
198203
"@google/generative-ai": "^0.18.0",
199204
"@modelcontextprotocol/sdk": "^1.0.1",
200205
"@types/clone-deep": "^4.0.4",

src/exports/cline.d.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,9 @@ export interface ClineAPI {
3434
* Simulates pressing the secondary button in the chat interface.
3535
*/
3636
pressSecondaryButton(): Promise<void>
37+
38+
/**
39+
* The sidebar provider instance.
40+
*/
41+
sidebarProvider: ClineSidebarProvider
3742
}

src/exports/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,8 @@ export function createClineAPI(outputChannel: vscode.OutputChannel, sidebarProvi
5656
invoke: "secondaryButtonClick",
5757
})
5858
},
59+
60+
sidebarProvider: sidebarProvider,
5961
}
6062

6163
return api

0 commit comments

Comments
 (0)