32 lines
761 B
Go
32 lines
761 B
Go
|
package database
|
||
|
|
||
|
import "testing"
|
||
|
|
||
|
func TestRedisStorageIsStorage(t *testing.T) {
|
||
|
var i interface{} = new(RedisStorage)
|
||
|
if _, ok := i.(Storage); !ok {
|
||
|
t.Fatalf("expected %t to implement Storage", i)
|
||
|
}
|
||
|
}
|
||
|
|
||
|
func TestRedisCertificateStorageIsCerts(t *testing.T) {
|
||
|
var i interface{} = new(redisCertificateStorage)
|
||
|
if _, ok := i.(Certs); !ok {
|
||
|
t.Fatalf("expected %t to implement Certs", i)
|
||
|
}
|
||
|
}
|
||
|
|
||
|
func TestRedisRouteStorageIsRoutes(t *testing.T) {
|
||
|
var i interface{} = new(redisRouteStorage)
|
||
|
if _, ok := i.(Routes); !ok {
|
||
|
t.Fatalf("expected %t to implement Routes", i)
|
||
|
}
|
||
|
}
|
||
|
|
||
|
func TestRedisTokenStorageIsTokens(t *testing.T) {
|
||
|
var i interface{} = new(redisTokenStorage)
|
||
|
if _, ok := i.(Tokens); !ok {
|
||
|
t.Fatalf("expected %t to implement Tokens", i)
|
||
|
}
|
||
|
}
|