(t *testing.T)
| 131 | } |
| 132 | |
| 133 | func 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 | } |
nothing calls this directly
no test coverage detected