From 63aac0edc59dd368050cb12a213af482dec71875 Mon Sep 17 00:00:00 2001 From: Michael Yang Date: Tue, 19 Dec 2023 15:02:37 -0800 Subject: [PATCH] fix(test): use real version string for comparison --- server/routes_test.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/server/routes_test.go b/server/routes_test.go index 7f3e4f05..07bb699d 100644 --- a/server/routes_test.go +++ b/server/routes_test.go @@ -16,6 +16,7 @@ import ( "github.com/jmorganca/ollama/api" "github.com/jmorganca/ollama/parser" + "github.com/jmorganca/ollama/version" ) func setupServer(t *testing.T) (*Server, error) { @@ -71,7 +72,7 @@ func Test_Routes(t *testing.T) { assert.Equal(t, contentType, "application/json; charset=utf-8") body, err := io.ReadAll(resp.Body) assert.Nil(t, err) - assert.Equal(t, `{"version":"0.0.0"}`, string(body)) + assert.Equal(t, fmt.Sprintf(`{"version":"%s"}`, version.Version), string(body)) }, }, {