From 42997b38408801fc386b5a705a418b0c5b3a1fc1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Olivier=20Mengu=C3=A9?= Date: Wed, 15 Mar 2023 00:28:13 +0100 Subject: [PATCH] tests: log value of IsTerminal Just log the output of IsTerminal in TestTerminal. $ go test -v -run TestTerminal === RUN TestTerminal isatty_others_test.go:13: os.Stdout: true --- PASS: TestTerminal (0.00s) PASS ok github.com/mattn/go-isatty 0.160s $ go test -v -run TestTerminal | cat === RUN TestTerminal isatty_others_test.go:13: os.Stdout: false --- PASS: TestTerminal (0.00s) PASS ok github.com/mattn/go-isatty 0.203s --- isatty_others_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/isatty_others_test.go b/isatty_others_test.go index 4c056bd..5ea708f 100644 --- a/isatty_others_test.go +++ b/isatty_others_test.go @@ -10,7 +10,7 @@ import ( func TestTerminal(t *testing.T) { // test for non-panic - IsTerminal(os.Stdout.Fd()) + t.Log("os.Stdout:", IsTerminal(os.Stdout.Fd())) } func TestCygwinPipeName(t *testing.T) {