You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
forgejo/tests
oliverpool 8030614386
fix: release page for empty or non-existing target (#24470)
Fixes #24145

To solve the bug, I added a "computed" `TargetBehind` field to the
`Release` model, which indicates the target branch of a release.
This is particularly useful if the target branch was deleted in the
meantime (or is empty).

I also did a micro-optimization in `calReleaseNumCommitsBehind`. Instead
of checking that a branch exists and then call `GetBranchCommit`, I
immediately call `GetBranchCommit` and handle the `git.ErrNotExist`
error.

This optimization is covered by the added unit test.
1 year ago
..
e2e Rewrite queue (#24505) 1 year ago
fuzz Move fuzz tests into tests/fuzz (#22376) 2 years ago
gitea-lfs-meta Test views of LFS files (#22196) 2 years ago
gitea-repositories-meta Remove git sample files and ignore them (#24271) 1 year ago
integration fix: release page for empty or non-existing target (#24470) 1 year ago
mssql.ini.tmpl Rewrite queue (#24505) 1 year ago
mysql.ini.tmpl Rewrite queue (#24505) 1 year ago
mysql8.ini.tmpl Rewrite queue (#24505) 1 year ago
pgsql.ini.tmpl Rewrite queue (#24505) 1 year ago
sqlite.ini.tmpl Rewrite queue (#24505) 1 year ago
test_utils.go Rewrite queue (#24505) 1 year ago