// TestQuery tests Query-handling.
TestQuery tests Query-handling.
// TestQuery tests Query - handling .
func TestQuery(t *testing.T) {
	log.Println("Reading environment file")
	err := godotenv.Load("../.env")
	if err != nil {
		err = errors.Wrap(err,
			".env file not found, env-vars will be read as set in environment",
		)
		log.Println(err)
	}
	missingVar, err := commonutil.ValidateEnv(
		"SERVICE_NAME",
		"KAFKA_BROKERS",
		"KAFKA_CONSUMER_TOPIC_REQUEST",
		"MONGO_HOSTS",
		"MONGO_USERNAME",
		"MONGO_PASSWORD",
		"MONGO_DATABASE",
		"MONGO_COLLECTION",
		"MONGO_CONNECTION_TIMEOUT_MS",
	)
	if err != nil {
		err = errors.Wrapf(err, "Env-var %s is required for testing, but is not set", missingVar)
		log.Fatalln(err)
	}
	RegisterFailHandler(Fail)
	RunSpecs(t, "QueryHandler Suite")
}
func TestQuery ( t * testing . T ) { log . Println ( " " ) err := godotenv . Load ( " " ) if err != nil { err = errors . Wrap ( err , " " , ) log . Println ( err ) } missingVar , err := commonutil . ValidateEnv ( " " , " " , " " , " " , " " , " " , " " , " " , " " , ) if err != nil { err = errors . Wrapf ( err , " " , missingVar ) log . Fatalln ( err ) } RegisterFailHandler ( Fail ) RunSpecs ( t , " " ) }
TestQuery tests Query-handling.
TestQuery tests Query - handling .