MCPcopy Create free account
hub / github.com/go-git/go-git / Files

Method Files

plumbing/format/diff/unified_encoder_test.go:1023–1035  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1021 return len(t.chunks) == 0
1022}
1023func (t testFilePatch) Files() (File, File) {
1024 // Go is amazing
1025 switch {
1026 case t.from == nil && t.to == nil:
1027 return nil, nil
1028 case t.from == nil:
1029 return nil, t.to
1030 case t.to == nil:
1031 return t.from, nil
1032 }
1033
1034 return t.from, t.to
1035}
1036
1037func (t testFilePatch) Chunks() []Chunk {
1038 var result []Chunk

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected