diff options
author | Steve Moyer <smoyer1@selesy.com> | 2023-01-17 06:38:00 -0500 |
---|---|---|
committer | Steve Moyer <smoyer1@selesy.com> | 2023-01-17 06:38:00 -0500 |
commit | a73640150d8f5c8492140f9d81e7b84542b95763 (patch) | |
tree | 34c235d01500421401e1234a73ae569137e36755 /commands/execenv/env_test.go | |
parent | 146037733472eb74429d6c053ccbb8087fe70bca (diff) | |
download | git-bug-a73640150d8f5c8492140f9d81e7b84542b95763.tar.gz |
feat: use isatty to detect a Termios instead
Diffstat (limited to 'commands/execenv/env_test.go')
-rw-r--r-- | commands/execenv/env_test.go | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/commands/execenv/env_test.go b/commands/execenv/env_test.go index 11ebdca1..3a59f187 100644 --- a/commands/execenv/env_test.go +++ b/commands/execenv/env_test.go @@ -15,36 +15,36 @@ func TestGetIOMode(t *testing.T) { name string in *os.File out *os.File - expInMode IOMode - expOutMode IOMode + expInMode bool + expOutMode bool }{ { name: "neither redirected", in: os.Stdin, out: os.Stdout, - expInMode: TerminalIOMode, - expOutMode: TerminalIOMode, + expInMode: false, + expOutMode: false, }, { name: "in redirected", in: w, out: os.Stdout, - expInMode: TerminalIOMode, - expOutMode: TerminalIOMode, + expInMode: true, + expOutMode: false, }, { name: "out redirected", in: os.Stdin, out: r, - expInMode: TerminalIOMode, - expOutMode: TerminalIOMode, + expInMode: false, + expOutMode: true, }, { name: "both redirected", in: w, out: r, - expInMode: PipedOrRedirectedIOMode, - expOutMode: PipedOrRedirectedIOMode, + expInMode: true, + expOutMode: true, }, } |