mirror of
https://codeberg.org/davrot/forgejo.git
synced 2025-06-12 20:00:02 +02:00
![]() * convert updateRepoUnits to not rely on ctx to retrieve the repo * Add integration test * do not activate releases if `wiki: true`. This is unexpected and there is no evidence it is necessary. Refs https://codeberg.org/forgejo/forgejo/issues/8082 --- The test is minimal for the sake of backporting. It is verified to reproduce the bug if the fix is not present. ```sh $ make TAGS='sqlite sqlite_unlock_notify' 'test-sqlite#TestAPIRepoMigrate' ... === TestAPIRepoMigrate (tests/integration/api_repo_test.go:388) --- FAIL: TestAPIRepoMigrate (1.12s) testlogger.go:411: 2025/06/11 17:38:22 ...les/storage/local.go:33:NewLocalStorage() [I] Creating new Local Storage at /home/earl-warren/software/forgejo/tests/gitea-lfs-meta testlogger.go:411: 2025/06/11 17:38:22 ...eb/routing/logger.go:102:func1() [I] router: completed GET /user/login for test-mock:12345, 200 OK in 2.1ms @ auth/auth.go:145(auth.SignIn) testlogger.go:411: 2025/06/11 17:38:22 ...eb/routing/logger.go:102:func1() [I] router: completed POST /user/login for test-mock:12345, 303 See Other in 2.1ms @ auth/auth.go:179(auth.SignInPost) testlogger.go:411: 2025/06/11 17:38:22 ...eb/routing/logger.go:102:func1() [I] router: completed GET /user/settings/applications for test-mock:12345, 200 OK in 3.8ms @ setting/applications.go:25(setting.Applications) testlogger.go:411: 2025/06/11 17:38:22 ...eb/routing/logger.go:102:func1() [I] router: completed POST /user/settings/applications for test-mock:12345, 303 See Other in 5.1ms @ setting/applications.go:35(setting.ApplicationsPost) testlogger.go:411: 2025/06/11 17:38:22 ...eb/routing/logger.go:102:func1() [I] router: completed GET /user/settings/applications for test-mock:12345, 200 OK in 2.9ms @ setting/applications.go:25(setting.Applications) testlogger.go:411: 2025/06/11 17:38:23 ...eb/routing/logger.go:102:func1() [I] router: completed POST /api/v1/repos/migrate for test-mock:12345, 0 in 992.0ms @ repo/migrate.go:38(repo.Migrate) api_repo_test.go:400: Error Trace: /home/earl-warren/software/forgejo/tests/integration/api_repo_test.go:400 Error: Not equal: expected: 201 actual : 200 Test: TestAPIRepoMigrate api_repo_test.go:402: Error Trace: /home/earl-warren/software/forgejo/tests/integration/integration_test.go:649 /home/earl-warren/software/forgejo/tests/integration/api_repo_test.go:402 Error: Received unexpected error: EOF Test: TestAPIRepoMigrate ``` ## Checklist The [contributor guide](https://forgejo.org/docs/next/contributor/) contains information that will be helpful to first time contributors. There also are a few [conditions for merging Pull Requests in Forgejo repositories](https://codeberg.org/forgejo/governance/src/branch/main/PullRequestsAgreement.md). You are also welcome to join the [Forgejo development chatroom](https://matrix.to/#/#forgejo-development:matrix.org). ### Tests - I added test coverage for Go changes... - [ ] in their respective `*_test.go` for unit tests. - [x] in the `tests/integration` directory if it involves interactions with a live Forgejo server. - I added test coverage for JavaScript changes... - [ ] in `web_src/js/*.test.js` if it can be unit tested. - [ ] in `tests/e2e/*.test.e2e.js` if it requires interactions with a live Forgejo server (see also the [developer guide for JavaScript testing](https://codeberg.org/forgejo/forgejo/src/branch/forgejo/tests/e2e/README.md#end-to-end-tests)). ### Documentation - [ ] I created a pull request [to the documentation](https://codeberg.org/forgejo/docs) to explain to Forgejo users how to use this change. - [x] I did not document these changes and I do not expect someone else to do it. ### Release notes - [ ] I do not want this change to show in the release notes. - [x] I want the title to show in the release notes with a link to this pull request. - [ ] I want the content of the `release-notes/<pull request number>.md` to be be used for the release notes instead of the title. <!--start release-notes-assistant--> ## Release notes <!--URL:https://codeberg.org/forgejo/forgejo--> - Bug fixes - [PR](https://codeberg.org/forgejo/forgejo/pulls/8155): <!--number 8155 --><!--line 0 --><!--description ZG8gbm90IGZhaWwgd2hlbiByZWxlYXNlIG9yIHdpa2kgaXMgc2V0IGluIGAvcmVwb3MvbWlncmF0ZWAgQVBJ-->do not fail when release or wiki is set in `/repos/migrate` API<!--description--> <!--end release-notes-assistant--> Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/8155 Reviewed-by: Lucas <sclu1034@noreply.codeberg.org> Co-authored-by: Earl Warren <contact@earl-warren.org> Co-committed-by: Earl Warren <contact@earl-warren.org> |
||
---|---|---|
.. | ||
action.go | ||
avatar.go | ||
blob.go | ||
branch.go | ||
collaborators.go | ||
commits.go | ||
compare.go | ||
download.go | ||
file.go | ||
flags.go | ||
fork.go | ||
git_hook.go | ||
git_ref.go | ||
hook.go | ||
hook_test.go | ||
issue.go | ||
issue_attachment.go | ||
issue_comment.go | ||
issue_comment_attachment.go | ||
issue_dependency.go | ||
issue_label.go | ||
issue_pin.go | ||
issue_reaction.go | ||
issue_stopwatch.go | ||
issue_subscription.go | ||
issue_tracked_time.go | ||
key.go | ||
label.go | ||
language.go | ||
main_test.go | ||
migrate.go | ||
milestone.go | ||
mirror.go | ||
notes.go | ||
patch.go | ||
pull.go | ||
pull_review.go | ||
release.go | ||
release_attachment.go | ||
release_tags.go | ||
repo.go | ||
repo_test.go | ||
star.go | ||
status.go | ||
subscriber.go | ||
sync_fork.go | ||
tag.go | ||
teams.go | ||
topic.go | ||
transfer.go | ||
tree.go | ||
wiki.go |