MCPcopy Index your code
hub / github.com/cortesi/modd / TestShells

Function TestShells

shell/shell_test.go:133–164  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

131}
132
133func TestShells(t *testing.T) {
134 shellTesting = true
135
136 var shells []string
137 if runtime.GOOS == "windows" {
138 shells = []string{
139 "modd",
140 "powershell",
141 }
142 } else {
143 shells = []string{
144 "sh",
145 "bash",
146 "modd",
147 "powershell",
148 }
149 }
150 for _, sh := range shells {
151 for _, tc := range shellTests {
152 t.Run(
153 fmt.Sprintf("%s/%s", sh, tc.name),
154 func(t *testing.T) {
155 if _, err := CheckShell(sh); err != nil {
156 t.Skipf("skipping - %s", err)
157 return
158 }
159 testCmd(t, sh, tc)
160 },
161 )
162 }
163 }
164}

Callers

nothing calls this directly

Calls 3

CheckShellFunction · 0.85
testCmdFunction · 0.85
RunMethod · 0.45

Tested by

no test coverage detected