wamr-ide: Add vscode extension tests (#2292)

This PR adds tests for #2219 by changing the `compilation_on_android_ubuntu.yml` workflow.
The first run will take about two hours, since LLDB is built from scratch. Later, the build is
cached and the whole job should not take more than three minutes.

Core of the PR is an integration test that boots up vscode and lets it debug a test WASM file.
This commit is contained in:
Ben Riegel
2023-06-20 08:33:01 +01:00
committed by GitHub
parent 85981b77b8
commit 72fc872afe
15 changed files with 511 additions and 22 deletions

View File

@ -40,7 +40,7 @@ let isWasmProject = false;
export async function activate(context: vscode.ExtensionContext) {
const extensionPath = context.extensionPath;
const osPlatform = os.platform();
const wamrVersion = getWAMRExtensionVersion(context);
const wamrVersion = getWAMRExtensionVersion(context.extensionPath);
const typeMap = new Map<string, string>();
const scriptMap = new Map<string, string>();
/* set relative path of build.bat|sh script */
@ -409,13 +409,13 @@ export async function activate(context: vscode.ExtensionContext) {
/* we should check again whether the user installed lldb, as this can be skipped during activation */
try {
if (!isLLDBInstalled(context)) {
if (!isLLDBInstalled(context.extensionPath)) {
/**NOTE - if users select to skip install,
* we should return rather than continue
* the execution
*/
if (
(await promptInstallLLDB(context)) ===
(await promptInstallLLDB(context.extensionPath)) ===
SelectionOfPrompt.skip
) {
return;
@ -772,8 +772,8 @@ export async function activate(context: vscode.ExtensionContext) {
);
try {
if (!isLLDBInstalled(context)) {
await promptInstallLLDB(context);
if (!isLLDBInstalled(context.extensionPath)) {
await promptInstallLLDB(context.extensionPath);
}
if (