}

		if router != nil {
			router.Stop()
		}
	})

	Context("NATS", func() {
		It("RouterGreets", func() {
			response := make(chan []byte)

			mbusClient.Subscribe("router.greet.test.response", func(msg *yagnats.Message) {
				response <- msg.Payload
			})

			mbusClient.PublishWithReplyTo("router.greet", "router.greet.test.response", []byte{})

			var msg []byte
			Eventually(response, 1).Should(Receive(&msg))
			Ω(string(msg)).To(MatchRegexp(".*\"minimumRegisterIntervalInSeconds\":5.*"))
		})

		It("discovers", func() {
			// Test if router responses to discover message
			sig := make(chan vcap.VcapComponent)

			// Since the form of uptime is xxd:xxh:xxm:xxs, we should make
			// sure that router has run at least for one second
			time.Sleep(time.Second)

			mbusClient.Subscribe("vcap.component.discover.test.response", func(msg *yagnats.Message) {