Files
cogito/client_test.go
Ettore Di Giacinto af41faaa19 Initial import
Signed-off-by: Ettore Di Giacinto <mudler@localai.io>
2025-09-23 23:24:00 +02:00

24 lines
514 B
Go

package cogito_test
import (
"context"
. "github.com/mudler/cogito"
. "github.com/onsi/ginkgo/v2"
. "github.com/onsi/gomega"
)
var _ = Describe("Client test", func() {
Context("A simple pipeline", func() {
It("should ask to the LLM", func() {
defaultLLM := NewLLM(defaultModel, "", apiEndpoint)
conv := NewEmptyFragment().AddMessage("user", "Hi!")
result, err := defaultLLM.Ask(context.TODO(), conv)
Expect(err).ToNot(HaveOccurred())
Expect(result.String()).ToNot(BeEmpty())
})
})
})