...

Source file src/github.com/gin-gonic/contrib/sessions/cookie_test.go

Documentation: github.com/gin-gonic/contrib/sessions

     1  package sessions
     2  
     3  import (
     4  	"testing"
     5  )
     6  
     7  var newCookieStore = func(_ *testing.T) Store {
     8  	store := NewCookieStore([]byte("secret"))
     9  	return store
    10  }
    11  
    12  func TestCookie_SessionGetSet(t *testing.T) {
    13  	sessionGetSet(t, newCookieStore)
    14  }
    15  
    16  func TestCookie_SessionDeleteKey(t *testing.T) {
    17  	sessionDeleteKey(t, newCookieStore)
    18  }
    19  
    20  func TestCookie_SessionFlashes(t *testing.T) {
    21  	sessionFlashes(t, newCookieStore)
    22  }
    23  
    24  func TestCookie_SessionClear(t *testing.T) {
    25  	sessionClear(t, newCookieStore)
    26  }
    27  
    28  func TestCookie_SessionOptions(t *testing.T) {
    29  	sessionOptions(t, newCookieStore)
    30  }
    31  

View as plain text