From 45d1dc9be0d9593736b59ad8aaaa61e0ebac4796 Mon Sep 17 00:00:00 2001 From: EwenQuim <ewen.quimerch@gmail.com> Date: Thu, 4 Jul 2024 09:48:14 +0200 Subject: [PATCH] Removed github.com/rs/cors from dependencies and added testing-from-outside to go.work --- go.work | 5 +++-- serve_test.go | 5 ----- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/go.work b/go.work index 357baa37..dd2da0a1 100644 --- a/go.work +++ b/go.work @@ -1,12 +1,13 @@ -go 1.22.2 +go 1.22.4 use ( . ./cmd/fuego + ./examples/acme-tls ./examples/basic ./examples/custom-serializer ./examples/full-app-gourmet ./examples/hello-world ./examples/openapi - ./examples/acme-tls + ./testing-from-outside ) diff --git a/serve_test.go b/serve_test.go index 40c4d59d..2e147d12 100644 --- a/serve_test.go +++ b/serve_test.go @@ -19,7 +19,6 @@ import ( "testing" "time" - "github.com/rs/cors" "github.com/stretchr/testify/require" ) @@ -392,10 +391,6 @@ func TestServer_Run(t *testing.T) { t.Run("can run server", func(t *testing.T) { s := NewServer( WithoutLogger(), - WithCorsMiddleware(cors.New(cors.Options{ - AllowedOrigins: []string{"*"}, - AllowedMethods: []string{"GET"}, - }).Handler), ) Get(s, "/test", func(ctx *ContextNoBody) (string, error) {