From 109508e12cab0605ddb38f10762040ba81270e1f Mon Sep 17 00:00:00 2001 From: Peter Bacon Darwin Date: Mon, 6 May 2024 14:48:16 +0100 Subject: [PATCH] fixup! fix(test): Fix execution for fake wrangler installation --- src/index.ts | 15 ++++++++++++--- .../mock_packages/wrangler/index.js | 3 +-- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/src/index.ts b/src/index.ts index c9b9b474..e864ffff 100755 --- a/src/index.ts +++ b/src/index.ts @@ -114,16 +114,25 @@ async function installWrangler() { ); } if (!config.didUserProvideWranglerVersion && installedVersion) { - info(`✅ No wrangler version specified, using pre-installed wrangler version ${installedVersion}`, true); + info( + `✅ No wrangler version specified, using pre-installed wrangler version ${installedVersion}`, + true, + ); endGroup(); return; } - if (config.didUserProvideWranglerVersion && installedVersionSatisfiesRequirement) { + if ( + config.didUserProvideWranglerVersion && + installedVersionSatisfiesRequirement + ) { info(`✅ Using Wrangler ${installedVersion}`, true); endGroup(); return; } - info('⚠️ Wrangler not found or version is incompatible. Installing...', true); + info( + "⚠️ Wrangler not found or version is incompatible. Installing...", + true, + ); } catch (error) { debug(`Error checking Wrangler version: ${error}`); info( diff --git a/test/pre-installed-wrangler/mock_packages/wrangler/index.js b/test/pre-installed-wrangler/mock_packages/wrangler/index.js index 105e8c89..b5d136d7 100755 --- a/test/pre-installed-wrangler/mock_packages/wrangler/index.js +++ b/test/pre-installed-wrangler/mock_packages/wrangler/index.js @@ -7,8 +7,7 @@ switch (command) { case "--version": console.log(` ⛅️ wrangler 1.1.1 (update available 1.2.3) -------------------------------------------` - ); +------------------------------------------`); process.exit(0); case "action-test": console.log("Test successful.");