feat: add files to compare (#6461)
Add the changed files between two commits to the response of the compare API, part of forgejo/forgejo#6460 Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/6461 Reviewed-by: Gusted <gusted@noreply.codeberg.org> Co-authored-by: Angel Nunez Mencias <git@angelnu.com> Co-committed-by: Angel Nunez Mencias <git@angelnu.com>
This commit is contained in:
parent
339814f3bc
commit
a2eb249766
4 changed files with 15 additions and 2 deletions
|
@ -35,6 +35,7 @@ func TestAPICompareBranches(t *testing.T) {
|
|||
|
||||
assert.Equal(t, 2, apiResp.TotalCommits)
|
||||
assert.Len(t, apiResp.Commits, 2)
|
||||
assert.Len(t, apiResp.Files, 3)
|
||||
}
|
||||
|
||||
func TestAPICompareCommits(t *testing.T) {
|
||||
|
@ -54,4 +55,5 @@ func TestAPICompareCommits(t *testing.T) {
|
|||
|
||||
assert.Equal(t, 2, apiResp.TotalCommits)
|
||||
assert.Len(t, apiResp.Commits, 2)
|
||||
assert.Len(t, apiResp.Files, 3)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue