note: the real test is to access os.File, io.Writer etc directly these funcs are just dummies to have something here to compile..
(fname string)
| 14 | // these funcs are just dummies to have something here to compile.. |
| 15 | |
| 16 | func OpenFile(fname string) *os.File { |
| 17 | f, err := os.Create(fname) |
| 18 | if err != nil { |
| 19 | log.Println(err) |
| 20 | return nil |
| 21 | } |
| 22 | return f |
| 23 | } |
| 24 | |
| 25 | func WriteToFile(w io.Writer, str string) { |
| 26 | _, err := w.Write([]byte(str)) |