mirror of
https://github.com/grafana/grafana.git
synced 2025-01-10 08:03:58 -06:00
caac9838d8
* Build: Fix integration cache tests * Allow REDIS_URL with scheme * Reduce cache integration tests timeout to 5m * Apply suggestion from code review * Run redis/memcached integration tests in OSS pipelines * Change redis image
25 lines
509 B
Go
25 lines
509 B
Go
package remotecache
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
|
|
"github.com/grafana/grafana/pkg/setting"
|
|
)
|
|
|
|
func TestIntegrationMemcachedCacheStorage(t *testing.T) {
|
|
if testing.Short() {
|
|
t.Skip("skipping integration test")
|
|
}
|
|
|
|
u, ok := os.LookupEnv("MEMCACHED_HOSTS")
|
|
if !ok || u == "" {
|
|
t.Skip("No Memcached hosts provided")
|
|
}
|
|
|
|
opts := &setting.RemoteCacheOptions{Name: memcachedCacheType, ConnStr: u}
|
|
client := createTestClient(t, opts, nil)
|
|
runTestsForClient(t, client)
|
|
runCountTestsForClient(t, opts, nil)
|
|
}
|