_, err = boshClient.Deploy(yaml) Expect(err).NotTo(HaveOccurred()) Eventually(func() ([]bosh.VM, error) { return helpers.DeploymentVMs(boshClient, manifest.Name) }, "1m", "10s").Should(ConsistOf(helpers.GetVMsFromManifest(manifest))) }) By("resolving the service address", func() { Eventually(func() ([]string, error) { return tcClient.DNS("some-service-name.service.cf.internal") }, "1m", "10s").Should(ConsistOf(manifest.InstanceGroups[0].Networks[0].StaticIPs)) }) By("causing the health check to fail", func() { err := tcClient.SetHealthCheck(false) Expect(err).NotTo(HaveOccurred()) }) By("the service should be deregistered", func() { Eventually(func() ([]string, error) { return tcClient.DNS("some-service-name.service.cf.internal") }, "1m", "10s").Should(BeEmpty()) }) By("causing the health check to succeed", func() { err := tcClient.SetHealthCheck(true) Expect(err).NotTo(HaveOccurred()) }) By("the service should be alive", func() {