MCPcopy Create free account
hub / github.com/CreminiAI/skillpack / withTempDir

Function withTempDir

tests/scheduler.test.ts:10–17  ·  view source on GitHub ↗
(run: (dir: string) => Promise<void> | void)

Source from the content-addressed store, hash-verified

8import { SchedulerAdapter } from "../src/runtime/adapters/scheduler.js";
9
10async function withTempDir(run: (dir: string) => Promise<void> | void): Promise<void> {
11 const dir = fs.mkdtempSync(path.join(os.tmpdir(), "skillpack-scheduler-"));
12 try {
13 await run(dir);
14 } finally {
15 fs.rmSync(dir, { recursive: true, force: true });
16 }
17}
18
19function createSchedulerContext(rootDir: string) {
20 return {

Callers 1

scheduler.test.tsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected