From bda762b10ef1def0dfb9121aa656cbb1352392e0 Mon Sep 17 00:00:00 2001 From: unkin-agent Date: Sun, 4 Oct 2026 22:11:19 +1100 Subject: [PATCH] Fix objects test compile after Routes evictor change (#130) ObjectsHandler.Routes now takes an Evictor, but TestObjectsListPrefix still calls it with no arguments, so the api/v2 test package fails to compile on master. - pass the existing fakeEvictor to Routes in objects_test.go Reviewed-on: https://git.unkin.net/unkin/artifactapi/pulls/130 Co-authored-by: unkin-agent Co-committed-by: unkin-agent --- internal/api/v2/objects_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/api/v2/objects_test.go b/internal/api/v2/objects_test.go index 7208055..fadb1c5 100644 --- a/internal/api/v2/objects_test.go +++ b/internal/api/v2/objects_test.go @@ -43,7 +43,7 @@ func TestObjectsListPrefix(t *testing.T) { } router := chi.NewRouter() - router.Mount("/remotes/{name}/objects", NewObjectsHandler(db).Routes()) + router.Mount("/remotes/{name}/objects", NewObjectsHandler(db).Routes(&fakeEvictor{})) list := func(query string) []models.Artifact { t.Helper()