add chat and generate tests with mock runner

This commit is contained in:
Michael Yang 2024-07-13 17:46:24 -07:00
parent 64039df6d7
commit 4a565cbf94
6 changed files with 679 additions and 14 deletions

View file

@ -7,11 +7,14 @@ import (
"slices"
"testing"
"github.com/gin-gonic/gin"
"github.com/ollama/ollama/api"
"github.com/ollama/ollama/envconfig"
)
func TestList(t *testing.T) {
gin.SetMode(gin.TestMode)
t.Setenv("OLLAMA_MODELS", t.TempDir())
envconfig.LoadConfig()