func initialize() *MemSearch { ms := new(MemSearch) ms.Init() testx.AddDocs(ms) return ms }
func initialize() *Elastic { addr := os.Getenv("ELASTICSEARCH_PORT_9200_TCP_ADDR") if len(addr) == 0 { return nil } es := new(Elastic) es.Init("http://" + addr + ":9200") es.DropIndex() testx.AddDocs(es) return es }