diff options
Diffstat (limited to 'std/examples/tests/colors_test.ts')
-rw-r--r-- | std/examples/tests/colors_test.ts | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/std/examples/tests/colors_test.ts b/std/examples/tests/colors_test.ts index 1a3e4f418..91d016232 100644 --- a/std/examples/tests/colors_test.ts +++ b/std/examples/tests/colors_test.ts @@ -1,11 +1,14 @@ // Copyright 2018-2020 the Deno authors. All rights reserved. MIT license. import { assertStrictEquals } from "../../testing/asserts.ts"; +import { resolve, dirname, fromFileUrl } from "../../path/mod.ts"; + +const moduleDir = resolve(dirname(fromFileUrl(import.meta.url)), ".."); Deno.test("[examples/colors] print a colored text", async () => { const decoder = new TextDecoder(); const process = Deno.run({ cmd: [Deno.execPath(), "run", "colors.ts"], - cwd: "examples", + cwd: moduleDir, stdout: "piped", }); try { |