diff options
Diffstat (limited to 'pkg/web/cookie/cookie_test.go')
| -rw-r--r-- | pkg/web/cookie/cookie_test.go | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/pkg/web/cookie/cookie_test.go b/pkg/web/cookie/cookie_test.go index 523e496..2f600f4 100644 --- a/pkg/web/cookie/cookie_test.go +++ b/pkg/web/cookie/cookie_test.go @@ -12,7 +12,7 @@ import ( func TestCookie(t *testing.T) { t.Run("New", func(t *testing.T) { t.Run("returns a cookie pinned to the HOST", func(t *testing.T) { - env.With(env.Vars{"HOST": "sparkle.example.com", "APP_ENV": "production"}, func() { + env.With(env.Vars{"HOST": "sparkle.example.com"}, func() { cookie := New("name", "value", time.Now().Add(1*time.Minute)) assert.Equal(t, "sparkle.example.com", cookie.Domain) assert.True(t, cookie.HttpOnly) @@ -20,14 +20,6 @@ func TestCookie(t *testing.T) { assert.Equal(t, http.SameSiteStrictMode, cookie.SameSite) }) }) - - t.Run("disables the secure flag for development", func(t *testing.T) { - env.With(env.Vars{"HOST": "sparkle.example.com", "APP_ENV": "development"}, func() { - cookie := New("name", "value", time.Now().Add(1*time.Minute)) - assert.True(t, cookie.HttpOnly) - assert.False(t, cookie.Secure) - }) - }) }) t.Run("Reset", func(t *testing.T) { |
