(t *testing.T)
| 1513 | } |
| 1514 | |
| 1515 | func TestBytesOutputsInputBytesUnchanged(t *testing.T) { |
| 1516 | t.Parallel() |
| 1517 | want := []byte{8, 0, 0, 16} |
| 1518 | input := bytes.NewReader(want) |
| 1519 | got, err := script.NewPipe().WithReader(input).Bytes() |
| 1520 | if err != nil { |
| 1521 | t.Fatal(err) |
| 1522 | } |
| 1523 | if !cmp.Equal(want, got) { |
| 1524 | t.Error(cmp.Diff(want, got)) |
| 1525 | } |
| 1526 | } |
| 1527 | |
| 1528 | func TestBytesReturnsErrorGivenReadErrorOnPipe(t *testing.T) { |
| 1529 | t.Parallel() |
nothing calls this directly
no test coverage detected
searching dependent graphs…