diff --git a/docker/linux/amd64/makefile b/docker/linux/amd64/makefile index 8c513a5..5aa75df 100644 --- a/docker/linux/amd64/makefile +++ b/docker/linux/amd64/makefile @@ -1,5 +1,5 @@ IMAGE := synadia/nats-surveyor -TAG := 0.0.1-alpha3 +TAG := 0.1.0 build: $(info Make: Building "$(TAG)" tagged images.) diff --git a/main.go b/main.go index 858671c..910bec9 100644 --- a/main.go +++ b/main.go @@ -26,7 +26,7 @@ import ( "github.com/nats-io/nats-surveyor/surveyor" ) -var version = "0.0.1" +var version = "0.1.0" func main() { var printVersion bool diff --git a/surveyor/observation_test.go b/surveyor/observation_test.go index 9b9bb8c..5126940 100644 --- a/surveyor/observation_test.go +++ b/surveyor/observation_test.go @@ -107,16 +107,22 @@ func TestServiceObservation_Handle(t *testing.T) { t.Fatalf("did not receive observations") } - // publish an invalid observation - err = sc.Clients[0].Publish("testing.topic", []byte{}) - if err != nil { - t.Fatalf("publish error: %s", err) + // publish some invalid observations + for i := 0; i < 10; i++ { + err = sc.Clients[0].Publish("testing.topic", []byte{}) + if err != nil { + t.Fatalf("publish error: %s", err) + } } - // wait for the invalid observation to arrive and then test for it - _, err = sub.NextMsg(time.Second) - if err != nil { - t.Fatalf("test subscriber didn't receive invalid message") + sc.Clients[0].Flush() + + for i := 0; i < 10; i++ { + // wait for the invalid observations to arrive + _, err = sub.NextMsg(time.Second) + if err != nil { + t.Fatalf("test subscriber didn't receive invalid message") + } } time.Sleep(250 * time.Microsecond)