github.com/machinefi/w3bstream@v1.6.5-rc9.0.20240426031326-b8c7c4876e72/pkg/depends/testutil/redistestutil/main_test.go (about) 1 package redistestutil_test 2 3 import ( 4 "testing" 5 6 . "github.com/onsi/gomega" 7 8 . "github.com/machinefi/w3bstream/pkg/depends/testutil/redistestutil" 9 ) 10 11 func TestInit(t *testing.T) { 12 NewWithT(t).Expect(Endpoint.Endpoint.String()).To(Equal("tcp://127.0.0.1:6379")) 13 NewWithT(t).Expect(Endpoint.Prefix).To(Equal("prod:test:")) 14 15 NewWithT(t).Expect(Redis.Host).To(Equal("127.0.0.1")) 16 NewWithT(t).Expect(Redis.Port).To(Equal(6379)) 17 } 18 19 func DISABLE_TestLivenessCheck(t *testing.T) { 20 kvs := Redis.LivenessCheck() 21 NewWithT(t).Expect(kvs[Redis.Host]).To(Equal("ok")) 22 23 kvs = Endpoint.LivenessCheck() 24 NewWithT(t).Expect(kvs[Endpoint.Endpoint.Host()]).To(Equal("ok")) 25 }