(t *testing.T, path, filename, content string)
| 2218 | } |
| 2219 | |
| 2220 | func createFileInPath(t *testing.T, path, filename, content string) (pathToFile string) { |
| 2221 | contentAsBytes := []byte(content) |
| 2222 | pathToFile = path + "/" + filename |
| 2223 | err := os.WriteFile(pathToFile, contentAsBytes, 0644) |
| 2224 | if err != nil { |
| 2225 | failWithFailure(t, "creating file "+filename+" with content "+content, "error") |
| 2226 | } |
| 2227 | return |
| 2228 | } |
| 2229 | |
| 2230 | func createExecutableFileInPath(t *testing.T, path, filename, content string) (pathToFile string) { |
| 2231 | ensureDirectoryExists(t, path) |
no test coverage detected