initial unified base tests#106
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5f46cf912a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Greptile SummaryThis PR consolidates previously duplicated adapter tests into a shared
Confidence Score: 4/5Safe to merge after adding a skip override for testGetPullRequestFromBranchNoPR in GitHubTest GitHubTest explicitly skips testGetPullRequestFromBranch because createBranch does not work in the GitHub test environment, but testGetPullRequestFromBranchNoPR — also introduced through Base — calls the same createBranch method without a matching skip, making CI failures on the GitHub adapter suite likely tests/VCS/Adapter/GitHubTest.php — the missing skip override for testGetPullRequestFromBranchNoPR is the one change needed before this can merge cleanly Important Files Changed
Reviews (7): Last reviewed commit: "test: migrate additional shared tests to..." | Re-trigger Greptile |
Migrates all shared adapter tests into Base.php following the dynamic pattern. All tests now create repos dynamically with uniqid() and clean up in finally blocks — no hardcoded owners, repos, or IDs.
Key changes:
Base.php fully rewritten with shared dynamic tests covering repository CRUD, tree, content, branches, commits, clone commands, pull requests, comments, search and owner
All adapter files implement setupAdapter() instead of setUp()
static::$owner and static::$defaultBranch used throughout
Duplicate tests removed from GiteaTest, GitLabTest, GitHubTest
Adapter-specific tests kept only where behavior genuinely differs
getOwnerName made consistent across GitLab and Gitea — requires repositoryId
Admin username changed to root across all adapters for consistency
testListBranchesEmptyRepo skipped in Base — each adapter overrides correctly