Files
bun.sh/packages/bun-vscode/scripts/dev.mjs
Ashcon Partovi 117e1b3883 bun run prettier (#14153)
Co-authored-by: Electroid <Electroid@users.noreply.github.com>
2024-09-24 22:46:18 -07:00

30 lines
945 B
JavaScript

import { defineConfig } from "@vscode/test-cli";
import { existsSync, mkdirSync, writeFileSync } from "node:fs";
import { dirname, join } from "node:path";
const workspacePath = dirname(import.meta.dirname);
const vscodePath = join(workspacePath, ".vscode-test");
const vscodeTestPath = join(vscodePath, "launch.test.js");
if (!existsSync(vscodeTestPath)) {
mkdirSync(vscodePath, { recursive: true });
writeFileSync(
vscodeTestPath,
`// Generated by ${import.meta.filename}
// A test that intentionally waits forever and does nothing,
// so you can debug and test the VSCode extension in a clean environment.
suite("VSCode extension", function () {
this.timeout(Number.MAX_SAFE_INTEGER);
test("wait forever", (done) => {});
});
`,
);
}
export default defineConfig({
workspaceFolder: join(workspacePath, "example"),
extensionDevelopmentPath: workspacePath,
skipExtensionDependencies: true,
files: vscodeTestPath,
});