| 1 | using AgentForge.Abstractions; |
| 2 | using AgentForge.Plugins; |
| 3 | |
| 4 | namespace AgentForge.Tests; |
| 5 | |
| 6 | public sealed class ForgePluginManifestLoaderTests |
| 7 | { |
| 8 | [Fact] |
| 9 | public void LoadToml_parses_active_bundle_and_plugins() |
| 10 | { |
| 11 | var path = Path.Combine(AppContext.BaseDirectory, "forge.plugins.toml"); |
| 12 | Assert.True(File.Exists(path), $"Expected manifest at {path}"); |
| 13 | |
| 14 | var manifest = ForgePluginManifestLoader.Load(path); |
| 15 | Assert.Equal("standard", manifest.ActiveBundle); |
| 16 | Assert.Equal(ForgePluginDiscovery.Manual, manifest.Host.Discovery); |
| 17 | Assert.True(manifest.Bundles.TryGetValue("standard", out var plugins)); |
| 18 | Assert.Equal(["view-shell", "oauth-web", "oauth-github", "issue", "merge-request"], plugins); |
| 19 | Assert.True(manifest.Plugins.ContainsKey("view-shell")); |
| 20 | Assert.Equal("AgentForge.Plugin.ViewShell.dll", manifest.Plugins["view-shell"].Assembly); |
| 21 | } |
| 22 | } |
| 23 | |
View only · write via MCP/CIDE