mirror of
https://github.com/openai/codex.git
synced 2026-11-22 07:13:50 +00:00
Infer the bundled Claude Code plugin marketplace (#34979)
## What changed - Treat enabled plugins from `claude-code-plugins` as coming from `anthropics/claude-code` when no marketplace source is already known. - Preserve an explicitly discovered source instead of replacing it with the inferred source. ## Testing - Add a migration test covering inference from `enabledPlugins`. GitOrigin-RevId: f061963356493027968e282a51538866d2bf31f4
This commit is contained in:
1 parent
ad65f016ed
commit
8d34c06672
2 files changed
+41
-10
No files matched your search
@@ -220,6 +220,30 @@ fn marketplace_import_sources_prefers_supported_declaration_over_materialization
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn marketplace_import_sources_infers_bundled_claude_code_marketplace() {
|
||||
let (_root, external_agent_home, _codex_home) = fixture_paths();
|
||||
let settings = serde_json::json!({
|
||||
"enabledPlugins": {
|
||||
"code-review@claude-code-plugins": true,
|
||||
}
|
||||
});
|
||||
|
||||
let import_sources = source_cla::marketplace_import_sources(
|
||||
&settings,
|
||||
&external_agent_home,
|
||||
&external_agent_home,
|
||||
);
|
||||
|
||||
assert_eq!(
|
||||
import_sources.get("claude-code-plugins"),
|
||||
Some(&MarketplaceImportSource {
|
||||
source: "anthropics/claude-code".to_string(),
|
||||
ref_name: None,
|
||||
})
|
||||
);
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn detect_home_plugins_uses_local_settings_over_project_settings() {
|
||||
let (_root, external_agent_home, codex_home) = fixture_paths();
|
||||
|
||||
Reference in new issue
Block a user