fix(forgejo-opencode-review): Test failures due to tempdir #39
No reviewers
Labels
No labels
plugin/bun2nix
plugin/cargo-build
plugin/cargo-clippy
plugin/cargo-nextest
plugin/cargo-publish
plugin/cargo-verify
plugin/command-suite
plugin/flake-checker
plugin/flake-lock-report
plugin/forgejo-file-sync
plugin/forgejo-opencode-review
plugin/forgejo-pr-merge
plugin/forgejo-release
plugin/new
plugin/nix-build
plugin/nixidy-cli
plugin/nixidy-switch
plugin/nix-unit
plugin/ntfy
plugin/oci-build-push
plugin/oci-copy
plugin/openapi-to-rust
plugin/path-filter
plugin/renovate-config-check
plugin/woodpecker-lint
type
feature
type
task
automerge
bug
dependencies
duplicate
help wanted
invalid
lang
rust
migrations
opencode
question
security
type
documentation
type
enhancement
type
maintenance
type
refactor
vulnerability
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Reference
Personal/woodpecker-plugins!39
Loading…
Reference in a new issue
No description provided.
Delete branch "nextest-fixes"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Review Summary
This PR refactors the
forgejo-opencode-reviewplugin to improve testability by introducing anOpenCodeRunnertrait for dependency injection, replacing the fragile PATH manipulation approach with a clean abstraction. TheOpenCodeBuilderin core now supports a configurable executable path. Tests are updated to useResultwith?operator instead ofunwrap(). The changes are well-structured and follow Rust best practices.Key improvements:
OpenCodeRunnertrait enables clean unit testingstd::env::set_varcalls in tests (which are deprecated in Rust 2024)cargo-nextestto dev shell for faster test runsNo correctness, security, or performance issues found.
*🤖 Review by opencode (opencode/nemotron-3-ultra-free) — verdict: approve