From e7848ea79a9a57fdf391d30c48ce649f3d2f6180 Mon Sep 17 00:00:00 2001 From: historia <[not public]> Date: Fri, 18 Sep 2026 21:44:49 -0400 Subject: refactor: dedup admin entity handlers and server construction --- internal/admin/hardening_security_test.go | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'internal/admin/hardening_security_test.go') diff --git a/internal/admin/hardening_security_test.go b/internal/admin/hardening_security_test.go index a077983..ba6b3dd 100644 --- a/internal/admin/hardening_security_test.go +++ b/internal/admin/hardening_security_test.go @@ -153,9 +153,13 @@ func TestStaticRequiresAuthAndDoesNotList(t *testing.T) { func newSecurityTestServer(t *testing.T) *AdminServer { t.Helper() h, _ := newEditorHarness(t) - s, err := NewServer(config.Default(), false, h.g.AccountStore, h.g.World, h.g.ItemStore, h.g.ObjectStore, - h.g.MobStore, h.dir, h.g.CourseStore.ReloadAll, h.g.MigrateRoomIDsOnOwner, h.g.EvictCasinoRoom, - h.g.RebuildCraftIndex, filepath.Join(h.dir, "config.yaml"), h.g.RunAdminOnOwner) + s, err := NewServer(ServerDeps{ + Config: config.Default(), Accounts: h.g.AccountStore, World: h.g.World, Items: h.g.ItemStore, + Objects: h.g.ObjectStore, Mobs: h.g.MobStore, DataDir: h.dir, + ReloadCourses: h.g.CourseStore.ReloadAll, RewriteRoomIDs: h.g.MigrateRoomIDsOnOwner, + EvictRoom: h.g.EvictCasinoRoom, RebuildCraftIndex: h.g.RebuildCraftIndex, + ConfigPath: filepath.Join(h.dir, "config.yaml"), RunOnOwner: h.g.RunAdminOnOwner, + }) if err != nil { t.Fatal(err) } -- cgit v1.2.3