package event

import (
	"testing"
	"time"
)

func TestEventbus(t *testing.T) {
	bus, err := NewEventbus([]string{"192.168.0.198:4222"}, "nats", "nats")
	if nil != err {
		t.Error(err.Error())
		return
	}
	defer bus.Close()

	bus.AsyncPub("ev.user", []byte("hello.lll"), 2*time.Second)

	t.Log("todo")
}
