mirror of
https://github.com/denoland/deno.git
synced 2024-10-30 09:08:00 -04:00
Testing add ansi color support from color module (denoland/deno_std#223)
Original: 90871cfca6
This commit is contained in:
parent
c131b8f3b6
commit
ef30a88542
1 changed files with 3 additions and 7 deletions
|
@ -1,6 +1,6 @@
|
|||
// Copyright 2018-2019 the Deno authors. All rights reserved. MIT license.
|
||||
|
||||
// Do not add imports in this file in order to be compatible with Node.
|
||||
import { green, red } from "../colors/mod.ts";
|
||||
|
||||
interface Constructor {
|
||||
new (...args: any[]): any;
|
||||
|
@ -233,16 +233,12 @@ function filter(name: string): boolean {
|
|||
}
|
||||
}
|
||||
|
||||
const RESET = "\x1b[0m";
|
||||
const FG_RED = "\x1b[31m";
|
||||
const FG_GREEN = "\x1b[32m";
|
||||
|
||||
function red_failed() {
|
||||
return FG_RED + "FAILED" + RESET;
|
||||
return red("FAILED");
|
||||
}
|
||||
|
||||
function green_ok() {
|
||||
return FG_GREEN + "ok" + RESET;
|
||||
return green("ok");
|
||||
}
|
||||
|
||||
export async function runTests() {
|
||||
|
|
Loading…
Reference in a new issue