helpers.LoginAsUser() }) It("confirms correct behavior in the lifecycle of a service broker", func() { defer helpers.Recover() // Catches panic thrown by Require expectations // Adding the service broker helpers.Require(Cf("create-service-broker", broker.Name, "username", "password", AppUri(broker.Name, "", LoadConfig().AppsDomain))).To(ExitWithTimeout(0, 10*time.Second)) Expect(Cf("service-brokers")).To(Say(broker.Name)) // Confirming the plans are not yet public session := Cf("marketplace") Expect(session).NotTo(Say(broker.Service.Name)) Expect(session).NotTo(Say(broker.Plan.Name)) broker.PublicizePlans() // Confirming plans show up in the marketplace session = Cf("marketplace") Expect(session).To(Say(broker.Service.Name)) Expect(session).To(Say(broker.Plan.Name)) // Changing the catalog on the broker oldServiceName := broker.Service.Name oldPlanName := broker.Plan.Name broker.Service.Name = generator.RandomName() broker.Plan.Name = generator.RandomName() broker.Configure() helpers.Require(Cf("update-service-broker", broker.Name, "username", "password", AppUri(broker.Name, "", LoadConfig().AppsDomain))).To(ExitWithTimeout(0, 10*time.Second)) // Confirming the changes to the broker show up in the marketplace