Consolidates three codebases into a single agent orchestration repo: - agentci (from go-scm): Clotho dual-run verification, agent config, SSH security (sanitisation, secure commands, token masking) - jobrunner (from go-scm): Poll-dispatch-report pipeline with 7 handlers (dispatch, completion, auto-merge, publish draft, dismiss reviews, send fix command, tick parent epic) - plugins marketplace (from agentic/plugins): 27 Claude/Codex/Gemini plugins with shared MCP server All 150+ tests passing across 6 packages. Co-Authored-By: Virgil <virgil@lethean.io>
52 lines
1.2 KiB
Go
52 lines
1.2 KiB
Go
package main
|
|
|
|
import (
|
|
"path/filepath"
|
|
"testing"
|
|
)
|
|
|
|
func TestMarketplaceLoad_Good(t *testing.T) {
|
|
marketplace, root, err := loadMarketplace()
|
|
if err != nil {
|
|
t.Fatalf("expected marketplace to load: %v", err)
|
|
}
|
|
if marketplace.Name == "" {
|
|
t.Fatalf("expected marketplace name to be set")
|
|
}
|
|
if len(marketplace.Plugins) == 0 {
|
|
t.Fatalf("expected marketplace plugins")
|
|
}
|
|
if root == "" {
|
|
t.Fatalf("expected repo root")
|
|
}
|
|
}
|
|
|
|
func TestMarketplacePluginInfo_Bad(t *testing.T) {
|
|
marketplace, _, err := loadMarketplace()
|
|
if err != nil {
|
|
t.Fatalf("expected marketplace to load: %v", err)
|
|
}
|
|
if _, ok := findMarketplacePlugin(marketplace, "missing-plugin"); ok {
|
|
t.Fatalf("expected missing plugin")
|
|
}
|
|
}
|
|
|
|
func TestMarketplacePluginInfo_Good(t *testing.T) {
|
|
marketplace, root, err := loadMarketplace()
|
|
if err != nil {
|
|
t.Fatalf("expected marketplace to load: %v", err)
|
|
}
|
|
|
|
plugin, ok := findMarketplacePlugin(marketplace, "claude-code")
|
|
if !ok {
|
|
t.Fatalf("expected claude-code plugin")
|
|
}
|
|
|
|
commands, err := listCommands(filepath.Join(root, plugin.Source))
|
|
if err != nil {
|
|
t.Fatalf("expected commands to list: %v", err)
|
|
}
|
|
if len(commands) == 0 {
|
|
t.Fatalf("expected commands for claude-code")
|
|
}
|
|
}
|