Commit Graph

17 Commits

Author SHA256 Message Date
79e5345ac6 test: refactor loggin in unit tests
Use test logger when running under a test.
2026-01-31 10:04:08 +01:00
c6ee055cb4 pr: add unit test for PrjGit PR to make sure we clone it
All checks were successful
go-generate-check / go-generate-check (push) Successful in 9s
This is unit test for previous commit
2026-01-30 16:23:25 +01:00
c2709e1894 fix unit tests and mocks
All checks were successful
go-generate-check / go-generate-check (push) Successful in 8s
2026-01-28 10:50:36 +01:00
c05fa236d1 pr: Add additional unit tests
- Add a test case specifically verifying that `Gitea.SetLabels`
  is called with `staging/Auto` when a *new* project PR is created
  for submodules.
- Verify `PrjGitDescription` and `SetSubmodulesToMatchPRSet` behave
  correctly when a single `PRSet` contains 5+ different package
  repositories.
2026-01-09 18:56:33 +01:00
abf8aa58fc pr: test PRProcessor that is triggered by webhook
- PullRequestWebhookEvent: Verified that PR events correctly
  trigger processing with all necessary Gitea and Git mocks.
- IssueCommentWebhookEvent: Verified that issue comment events
  (which Gitea often uses for PR comments) are handled correctly.
- Recursion Limit: Verified that the recursion protection logic
  correctly terminates and cleans up when the limit is reached.
- Invalid Data Format: Verified that non-event data types return
  appropriate errors.
2026-01-09 16:59:29 +01:00
4f132ec154 pr: test verifyRepositoryConfiguration 2026-01-09 16:41:25 +01:00
86a7fd072e pr: add test cases for PRProcessor corner cases
- Add scenarios for closed/merged project PRs that trigger
   submodule checks and downstream PR updates (manual merge vs close).
- Test the "Consistency check" logic where submodules are reset
  if they don't match the PR set.
- Test the "superfluous PR" check (no-op PRs that should be closed).
2026-01-09 16:34:07 +01:00
5f5e7d98b5 pr: add some tests for UpdatePrjGitPR 2026-01-09 13:59:02 +01:00
e8738c9585 pr: add tests for RebaseAndSkipSubmoduleCommits 2026-01-09 13:44:53 +01:00
b7f5c97de1 pr: add error handling unit tests 2026-01-08 22:21:33 +01:00
37c9cc7a57 add PRProcessor tests 2026-01-08 20:57:18 +01:00
e92ac4a592 PR: refactor 2025-06-12 23:51:04 +02:00
e30d366f2f workflow-pr: logging updates 2025-04-29 18:00:37 +02:00
da1f4f4fa0 fix mocks 2025-04-04 13:05:51 +02:00
92747f0913 {wip} 2025-01-21 17:19:18 +01:00
8c6180a8cf . 2024-12-15 13:00:20 +01:00
2d12899da5 workflow-pr: renamed files 2024-12-01 11:36:26 +01:00