MCPcopy Create free account
hub / github.com/astercloud/aster / TestMultiProviderFactory_Create_Anthropic

Function TestMultiProviderFactory_Create_Anthropic

pkg/provider/factory_test.go:16–33  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

14}
15
16func TestMultiProviderFactory_Create_Anthropic(t *testing.T) {
17 factory := NewMultiProviderFactory()
18
19 config := &types.ModelConfig{
20 Provider: "anthropic",
21 APIKey: "test-key",
22 Model: "claude-3-opus",
23 }
24
25 provider, err := factory.Create(config)
26 if err != nil {
27 t.Fatalf("Create failed: %v", err)
28 }
29
30 if provider == nil {
31 t.Error("expected provider, got nil")
32 }
33}
34
35func TestMultiProviderFactory_Create_OpenAI(t *testing.T) {
36 factory := NewMultiProviderFactory()

Callers

nothing calls this directly

Calls 3

CreateMethod · 0.95
NewMultiProviderFactoryFunction · 0.85
ErrorMethod · 0.65

Tested by

no test coverage detected