MCPcopy Index your code
hub / github.com/bitfield/script / TestSliceGivenEmptySliceProducesEmptyPipe

Function TestSliceGivenEmptySliceProducesEmptyPipe

script_test.go:1433–1443  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

1431}
1432
1433func TestSliceGivenEmptySliceProducesEmptyPipe(t *testing.T) {
1434 t.Parallel()
1435 want := ""
1436 got, err := script.Slice([]string{}).String()
1437 if err != nil {
1438 t.Fatal(err)
1439 }
1440 if want != got {
1441 t.Fatalf("want %q, got %q", want, got)
1442 }
1443}
1444
1445func TestStdoutReturnsErrorGivenReadErrorOnPipe(t *testing.T) {
1446 t.Parallel()

Callers

nothing calls this directly

Calls 2

SliceFunction · 0.92
StringMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…