[PR #2453] [CLOSED] Add more repo search tests and /api/repo/search integration tests #16406

Closed
opened 2025-11-02 12:09:52 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/go-gitea/gitea/pull/2453
Author: @Morlinest
Created: 9/2/2017
Status: Closed

Base: masterHead: feature/repo-search-tests


📝 Commits (6)

  • c7b650a Add more repo search tests
  • f8de1aa Add and fix /api/repo/search integration tests
  • 9605731 Add owner to access table for organization repositories
  • 9961720 Fix repo search tests
  • 10791c3 Always test returned repos length
  • b9d56db Add test with lower pagesize limit (test more pages)

📊 Changes

10 files changed (+549 additions, -18 deletions)

View changed files

📝 integrations/api_repo_test.go (+219 -9)
📝 models/fixtures/access.yml (+24 -0)
📝 models/fixtures/org_user.yml (+8 -0)
📝 models/fixtures/repository.yml (+97 -0)
📝 models/fixtures/team.yml (+9 -0)
📝 models/fixtures/team_repo.yml (+12 -0)
📝 models/fixtures/team_user.yml (+6 -0)
📝 models/fixtures/user.yml (+47 -0)
📝 models/org_test.go (+1 -1)
📝 models/repo_list_test.go (+126 -8)

📄 Description

Add some more tests. Also fixes #2446.

Two integration tests will not pass with current implementation of repo search api because it doesn't return all repositories accessible to user if he is not logged or is different from logged user


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/go-gitea/gitea/pull/2453 **Author:** [@Morlinest](https://github.com/Morlinest) **Created:** 9/2/2017 **Status:** ❌ Closed **Base:** `master` ← **Head:** `feature/repo-search-tests` --- ### 📝 Commits (6) - [`c7b650a`](https://github.com/go-gitea/gitea/commit/c7b650a47d49e280541bbc63a3efe0f6f120b403) Add more repo search tests - [`f8de1aa`](https://github.com/go-gitea/gitea/commit/f8de1aa59a259268bf652e9dded4acf0752c87bb) Add and fix /api/repo/search integration tests - [`9605731`](https://github.com/go-gitea/gitea/commit/9605731c4dc885a794175497b86f41bfd2076dab) Add owner to access table for organization repositories - [`9961720`](https://github.com/go-gitea/gitea/commit/99617206061c5be94f9affdf05d806178254c229) Fix repo search tests - [`10791c3`](https://github.com/go-gitea/gitea/commit/10791c337574bcfc33c5c8b810bd6b12c9113a31) Always test returned repos length - [`b9d56db`](https://github.com/go-gitea/gitea/commit/b9d56dba42a20bfd6b90bb9f06230e266304cf22) Add test with lower pagesize limit (test more pages) ### 📊 Changes **10 files changed** (+549 additions, -18 deletions) <details> <summary>View changed files</summary> 📝 `integrations/api_repo_test.go` (+219 -9) 📝 `models/fixtures/access.yml` (+24 -0) 📝 `models/fixtures/org_user.yml` (+8 -0) 📝 `models/fixtures/repository.yml` (+97 -0) 📝 `models/fixtures/team.yml` (+9 -0) 📝 `models/fixtures/team_repo.yml` (+12 -0) 📝 `models/fixtures/team_user.yml` (+6 -0) 📝 `models/fixtures/user.yml` (+47 -0) 📝 `models/org_test.go` (+1 -1) 📝 `models/repo_list_test.go` (+126 -8) </details> ### 📄 Description Add some more tests. Also fixes #2446. Two integration tests will not pass with current implementation of repo search api because it doesn't return all repositories accessible to user if he is not logged or is different from logged user --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-02 12:09:52 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#16406