Use AbsolutePathBuf in skill loading and codex_home (#17407)

Helps with FS migration later
This commit is contained in:
pakrym-oai authored and GitHub committed 2026-04-13 10:26:51 -07:00
1 parent d25a9822a7
commit ac82443d07
86 files changed
+850 -625

No files matched your search

@@ -4008,6 +4008,8 @@ impl ChatComposer {
#[cfg(test)]
mod tests {
use super::*;
use crate::test_support::PathBufExt;
use crate::test_support::test_path_buf;
use image::ImageBuffer;
use image::Rgba;
use pretty_assertions::assert_eq;
@@ -5053,6 +5055,7 @@ mod tests {
#[test]
fn mention_items_show_plugin_owned_skill_and_app_duplicates() {
let skill_path = test_path_buf("/tmp/repo/google-calendar/SKILL.md").abs();
let (tx, _rx) = unbounded_channel::<AppEvent>();
let sender = AppEventSender::new(tx);
let mut composer = ChatComposer::new(
@@ -5078,7 +5081,7 @@ mod tests {
}),
dependencies: None,
policy: None,
path_to_skills_md: PathBuf::from("/tmp/repo/google-calendar/SKILL.md"),
path_to_skills_md: skill_path.clone(),
scope: codex_protocol::protocol::SkillScope::Repo,
}]));
composer.set_plugin_mentions(Some(vec![PluginCapabilitySummary {
@@ -5115,10 +5118,7 @@ mod tests {
let mentions = composer.mention_items();
assert_eq!(mentions.len(), 3);
assert_eq!(mentions[0].category_tag, Some("[Skill]".to_string()));
assert_eq!(
mentions[0].path,
Some("/tmp/repo/google-calendar/SKILL.md".to_string())
);
assert_eq!(mentions[0].path, Some(skill_path.display().to_string()));
assert_eq!(mentions[0].display_name, "Google Calendar".to_string());
assert_eq!(mentions[1].category_tag, Some("[Plugin]".to_string()));
assert_eq!(
@@ -5176,7 +5176,7 @@ mod tests {
}),
dependencies: None,
policy: None,
path_to_skills_md: PathBuf::from("/tmp/repo/google-calendar/SKILL.md"),
path_to_skills_md: test_path_buf("/tmp/repo/google-calendar/SKILL.md").abs(),
scope: codex_protocol::protocol::SkillScope::Repo,
}]));
composer.set_plugin_mentions(Some(vec![PluginCapabilitySummary {