Publish the exact sanitized Agent Skill and VS Code preview source tree with independent license boundaries, deterministic provenance manifests, and no private development history. Material design and implementation assistance was provided by OpenAI Codex. Signed-off-by: Cole Speelman <crspeelman@gmail.com>
30 lines
1.2 KiB
JavaScript
30 lines
1.2 KiB
JavaScript
// SPDX-License-Identifier: AGPL-3.0-only
|
|
'use strict';
|
|
const fs = require('node:fs');
|
|
const os = require('node:os');
|
|
const path = require('node:path');
|
|
const {downloadAndUnzipVSCode, runTests} = require('@vscode/test-electron');
|
|
|
|
(async () => {
|
|
const extensionDevelopmentPath = path.resolve(__dirname, '..', '..');
|
|
const sourceWorkspace = path.join(extensionDevelopmentPath, 'test', 'workspace');
|
|
const temporary = fs.mkdtempSync(path.join(os.tmpdir(), 'himesan-vscode-integration-'));
|
|
const workspace = path.join(temporary, 'project [safe]');
|
|
fs.cpSync(sourceWorkspace, workspace, {recursive: true});
|
|
try {
|
|
const vscodeExecutablePath = await downloadAndUnzipVSCode('1.96.4');
|
|
await runTests({
|
|
vscodeExecutablePath,
|
|
extensionDevelopmentPath,
|
|
extensionTestsPath: path.join(__dirname, 'suite', 'index.js'),
|
|
launchArgs: [workspace, '--disable-extensions', '--disable-gpu', '--skip-welcome', '--skip-release-notes'],
|
|
extensionTestsEnv: {HIMESAN_TEST_BINARY: process.env.HIMESAN_TEST_BINARY || ''},
|
|
});
|
|
} finally {
|
|
fs.rmSync(temporary, {recursive: true, force: true});
|
|
}
|
|
})().catch((error) => {
|
|
console.error(error);
|
|
process.exitCode = 1;
|
|
});
|