We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 950e6e1 commit 6189603Copy full SHA for 6189603
pipes_test.go
@@ -25,8 +25,10 @@ func TestWithReader(t *testing.T) {
25
t.Errorf("want %q, got %q", want, got)
26
}
27
28
+
29
func TestWithError(t *testing.T) {
- p := File("testdata/empty.txt")
30
+ t.Parallel()
31
+ p := script.File("testdata/empty.txt")
32
want := "fake error"
33
_, gotErr := p.WithError(errors.New(want)).String()
34
if gotErr.Error() != "fake error" {
@@ -36,7 +38,7 @@ func TestWithError(t *testing.T) {
36
38
if err == nil {
37
39
t.Error("input not closed after reading")
40
- p = File("testdata/empty.txt")
41
+ p = script.File("testdata/empty.txt")
42
_, gotErr = p.WithError(nil).String()
43
if gotErr != nil {
44
t.Errorf("got unexpected error: %q", gotErr.Error())
0 commit comments