aboutsummaryrefslogtreecommitdiffstats
path: root/plumbing/protocol/packp/advrefs_decode_test.go
diff options
context:
space:
mode:
authorPaulo Gomes <pjbgf@linux.com>2023-07-02 12:05:17 +0100
committerGitHub <noreply@github.com>2023-07-02 12:05:17 +0100
commit99ccca6bc543f88a18df50763d5fc13808e053e4 (patch)
treebb6716d60d897e2c1c5f485509aca30c3bb73f7e /plumbing/protocol/packp/advrefs_decode_test.go
parent4e1b9c8c558bceef1c773022c94afd4d746b7b81 (diff)
parentabe49196b80e367f7cc123a095b32958f8d0470b (diff)
downloadgo-git-99ccca6bc543f88a18df50763d5fc13808e053e4.tar.gz
Merge pull request #802 from pjbgf/fix-build
plumbing: http, Fix empty repos on Git v2.41+
Diffstat (limited to 'plumbing/protocol/packp/advrefs_decode_test.go')
-rw-r--r--plumbing/protocol/packp/advrefs_decode_test.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/plumbing/protocol/packp/advrefs_decode_test.go b/plumbing/protocol/packp/advrefs_decode_test.go
index 83b0b01..d127145 100644
--- a/plumbing/protocol/packp/advrefs_decode_test.go
+++ b/plumbing/protocol/packp/advrefs_decode_test.go
@@ -218,6 +218,16 @@ func (s *AdvRefsDecodeSuite) TestCaps(c *C) {
{Name: capability.SymRef, Values: []string{"HEAD:refs/heads/master"}},
{Name: capability.Agent, Values: []string{"foo=bar"}},
},
+ }, {
+ input: []string{
+ "0000000000000000000000000000000000000000 capabilities^{}\x00report-status report-status-v2 delete-refs side-band-64k quiet atomic ofs-delta object-format=sha1 agent=git/2.41.0\n",
+ pktline.FlushString,
+ },
+ capabilities: []entry{
+ {Name: capability.ReportStatus, Values: []string(nil)},
+ {Name: capability.ObjectFormat, Values: []string{"sha1"}},
+ {Name: capability.Agent, Values: []string{"git/2.41.0"}},
+ },
}} {
ar := s.testDecodeOK(c, test.input)
for _, fixCap := range test.capabilities {