diff --git a/deno.lock b/deno.lock index 6cb45c0c..f2a22b0c 100644 --- a/deno.lock +++ b/deno.lock @@ -15,6 +15,7 @@ "jsr:@std/jsonc@0.217": "jsr:@std/jsonc@0.217.0", "jsr:@std/path@0.217": "jsr:@std/path@0.217.0", "jsr:@std/semver@0.217": "jsr:@std/semver@0.217.0", + "jsr:@std/semver@0.224.3": "jsr:@std/semver@0.224.3", "jsr:@std/streams@0.217": "jsr:@std/streams@0.217.0", "npm:keychain@1.5.0": "npm:keychain@1.5.0" }, @@ -65,6 +66,9 @@ "@std/semver@0.217.0": { "integrity": "c1ba42cdcaacf610f1a62ec2256ab29765a73fede65120214c3acb9c85ed3d35" }, + "@std/semver@0.224.3": { + "integrity": "7bb34b5ad46de2c0c73de0ca3e30081ef64b4361f66abd57c84ff1011c6a1233" + }, "@std/streams@0.217.0": { "integrity": "b4a6de703d6aa59c4777f89fc002e82b8401dada44d1e6f7e916664c1e6cfd36" } diff --git a/src/subcommands/logs_test.ts b/src/subcommands/logs_test.ts index 23cef9bb..4383c2f3 100644 --- a/src/subcommands/logs_test.ts +++ b/src/subcommands/logs_test.ts @@ -1,6 +1,7 @@ import { parseArgsForLogSubcommand } from "./logs.ts"; import { assertEquals, assertThrows } from "jsr:@std/assert@0.217"; import { parseArgs } from "../args.ts"; +import { greaterOrEqual, parse } from "jsr:@std/semver@0.224.3"; Deno.test("parseArgsForLogSubcommand", async (t) => { const parseHelper = (args: string[]) => { @@ -15,7 +16,11 @@ Deno.test("parseArgsForLogSubcommand", async (t) => { // to fail unexpectedly (not sure if this is intended). To avoid this, we // set `Deno.exitCode` to 0 before giving control back to each test case. // https://github.com/denoland/deno/pull/23609 - Deno.exitCode = 0; + const EXIT_CODE_MIN_VERSION = parse("1.44.0"); + const currentVersion = parse(Deno.version.deno); + if (greaterOrEqual(currentVersion, EXIT_CODE_MIN_VERSION)) { + Deno.exitCode = 0; + } throw e; } };