github.com/sercand/please@v13.4.0+incompatible/test/parse_test/additional_output_test.go (about) 1 // Test on adding extra output files to a target in a post-build function. 2 package parse 3 4 import "io/ioutil" 5 import "testing" 6 7 func TestContentsOfOutputFile(t *testing.T) { 8 contents, err := ioutil.ReadFile("test/parse_test/test_additional_output.txt") 9 if err != nil { 10 t.Errorf("Failed to read additional output file: %s", err) 11 } 12 if string(contents) != "kittens" { 13 t.Errorf("Unexpected file contents: was '%s', expected 'kittens'", string(contents)) 14 } 15 }