Path: redb-route/tests/redb.Route.Tests.Llm/LlmComponentTests.cs Snapshot: redb-route, development snapshot 2026-12-06. This is the development state of the public mirrors; it may differ from the published packages. License: Apache-2.0. Repository: https://github.com/redbase-app/redb-route Page: https://redbase.app/src/dev-2026-12-06/redb-route/tests/redb.Route.Tests.Llm/LlmComponentTests.cs ---- namespace redb.Route.Tests.Llm; public sealed class LlmComponentTests { [Fact] public void Scheme_IsLlm() { new LlmComponent().Scheme.Should().Be("llm"); } [Fact] public void CreateEndpoint_ParsesPathAsFactoryName() { var component = new LlmComponent(); var uri = EndpointUriParser.Parse("llm://claude?temperature=0.2"); var endpoint = (LlmEndpoint)component.CreateEndpoint(uri); endpoint.ConnectionFactoryName.Should().Be("claude"); endpoint.Uri.RawParameters["temperature"].Should().Be("0.2"); } [Fact] public void CreateEndpoint_FactoryNameViaQuery_Works() { var component = new LlmComponent(); var uri = EndpointUriParser.Parse("llm://?connectionFactory=local"); var endpoint = (LlmEndpoint)component.CreateEndpoint(uri); endpoint.ConnectionFactoryName.Should().Be("local"); } [Fact] public void CreateEndpoint_NoFactoryName_Throws() { var component = new LlmComponent(); var uri = EndpointUriParser.Parse("llm://?temperature=0.1"); var act = () => component.CreateEndpoint(uri); act.Should().Throw().WithMessage("*connection factory*"); } [Fact] public void CreateEndpoint_InvalidTemperature_Throws() { var component = new LlmComponent(); var uri = EndpointUriParser.Parse("llm://c?temperature=5.0"); var act = () => component.CreateEndpoint(uri); act.Should().Throw(); } [Fact] public void CreateEndpoint_NullUri_Throws() { var component = new LlmComponent(); var act = () => component.CreateEndpoint(null!); act.Should().Throw(); } }