Refactor client facade into modular components#1659
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ 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".
| fn resolve_destination_path(destination_root: &Path, relative: &Path) -> PathBuf { | ||
| let candidate = destination_root.join(relative); | ||
| if candidate.exists() { | ||
| return candidate; | ||
| } | ||
|
|
||
| if destination_root | ||
| .file_name() | ||
| .is_some_and(|file_name| relative == Path::new(file_name)) | ||
| { | ||
| return destination_root.to_path_buf(); | ||
| } | ||
|
|
||
| candidate | ||
| } |
There was a problem hiding this comment.
Expose resolve_destination_path for tests
The new module split moves ClientEvent::resolve_destination_path into the summary submodule where it remains private (fn resolve_destination_path). The unit tests still call ClientEvent::resolve_destination_path(...) from client/tests.rs, but sibling modules cannot access a private method defined inside summary, so cargo test -p rsync-core will now fail to compile. Consider making the helper pub(crate) or updating the tests to avoid calling the private API.
Useful? React with 👍 / 👎.
Summary
Testing
https://chatgpt.com/codex/tasks/task_e_69033e9b20d483238227fd6b3d1f83c5