aboutsummaryrefslogtreecommitdiffstats
path: root/commands/execenv/env_test.go
diff options
context:
space:
mode:
authorSteve Moyer <smoyer1@selesy.com>2023-01-17 06:38:00 -0500
committerSteve Moyer <smoyer1@selesy.com>2023-01-17 06:38:00 -0500
commita73640150d8f5c8492140f9d81e7b84542b95763 (patch)
tree34c235d01500421401e1234a73ae569137e36755 /commands/execenv/env_test.go
parent146037733472eb74429d6c053ccbb8087fe70bca (diff)
downloadgit-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.go20
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,
},
}