From 776e5d8741bb52bdae7c0808e0601ee21f877946 Mon Sep 17 00:00:00 2001 From: Peter Cardenas <16930781+PeterCardenas@users.noreply.github.com> Date: Sun, 16 Mar 2025 13:39:13 -0700 Subject: [PATCH] fix: ensure tests directory exists before checking it --- src/commands/patches/copy-patches.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/commands/patches/copy-patches.ts b/src/commands/patches/copy-patches.ts index 671929e..3c6c540 100644 --- a/src/commands/patches/copy-patches.ts +++ b/src/commands/patches/copy-patches.ts @@ -8,7 +8,7 @@ import { copyFile } from 'node:fs/promises' import { dirname, resolve } from 'node:path' import glob from 'tiny-glob' -import { appendToFileSync, mkdirp } from '../../utils' +import { appendToFileSync, ensureDirectory, mkdirp } from '../../utils' import { config } from '../..' import { CURRENT_DIR, ENGINE_DIR, SRC_DIR, TESTS_DIR } from '../../constants' import { IMelonPatch } from './command' @@ -104,6 +104,7 @@ export async function get(): Promise { } }) + await ensureDirectory('./tests') const testFiles = await glob('./tests/**/*', { filesOnly: true, cwd: '.',