MCPcopy Create free account
hub / github.com/bufbuild/buf / TestEmptyFiles

Function TestEmptyFiles

private/bufpkg/bufimage/bufimageutil/bufimageutil_test.go:637–647  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

635}
636
637func TestEmptyFiles(t *testing.T) {
638 t.Parallel()
639 t.Run("include_empty_file", func(t *testing.T) {
640 t.Parallel()
641 runDiffTest(t, "testdata/empty", "empty.include.txtar", WithIncludeTypes("include"))
642 })
643 t.Run("exclude_empty_file", func(t *testing.T) {
644 t.Parallel()
645 runDiffTest(t, "testdata/empty", "empty.exclude.txtar", WithExcludeTypes("include"))
646 })
647}
648
649func getImage(ctx context.Context, logger *slog.Logger, testdataDir string, options ...bufimage.BuildImageOption) (storage.ReadWriteBucket, bufimage.Image, error) {
650 bucket, err := storageos.NewProvider().NewReadWriteBucket(testdataDir)

Callers

nothing calls this directly

Calls 4

runDiffTestFunction · 0.85
WithIncludeTypesFunction · 0.85
WithExcludeTypesFunction · 0.85
RunMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…