hardware-tests/lib/io.go
Gregory Ballantine 90f679c366
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Added result logging functionality (#2)
All test commands now utilize the "-l" or "--log" flag to specify a file to log results to.

Reviewed-on: #2
2022-02-26 20:48:37 -05:00

17 lines
220 B
Go

package lib
import (
"fmt"
"os"
)
func WriteToFile(filepath string, content string) {
file, err := os.Create(filepath)
if err != nil {
fmt.Println(err)
} else {
file.WriteString(content)
}
file.Close()
}