1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-27 04:38:36 +00:00

Fix bug on getIssueIDsByRepoID (#16119) (#16124)

* Fix bug on getIssueIDsByRepoID

* Add test
This commit is contained in:
Lunny Xiao
2021-06-10 13:12:18 +08:00
committed by GitHub
parent ac84bb7183
commit 41a4047e79
2 changed files with 9 additions and 1 deletions

View File

@@ -36,6 +36,14 @@ func TestIssue_ReplaceLabels(t *testing.T) {
testSuccess(1, []int64{})
}
func Test_GetIssueIDsByRepoID(t *testing.T) {
assert.NoError(t, PrepareTestDatabase())
ids, err := GetIssueIDsByRepoID(1)
assert.NoError(t, err)
assert.Len(t, ids, 5)
}
func TestIssueAPIURL(t *testing.T) {
assert.NoError(t, PrepareTestDatabase())
issue := AssertExistsAndLoadBean(t, &Issue{ID: 1}).(*Issue)