github.com/randomtask1155/cli@v6.41.1-0.20181227003417-a98eed78cbde+incompatible/integration/v7/push/no_route_flag_test.go (about) 1 package push 2 3 import ( 4 "code.cloudfoundry.org/cli/integration/helpers" 5 . "github.com/onsi/ginkgo" 6 . "github.com/onsi/gomega" 7 . "github.com/onsi/gomega/gbytes" 8 . "github.com/onsi/gomega/gexec" 9 ) 10 11 var _ = When("the --no-route flag is set", func() { 12 var ( 13 appName string 14 ) 15 16 BeforeEach(func() { 17 appName = helpers.PrefixedRandomName("app") 18 }) 19 20 It("does not map any routes to the app", func() { 21 helpers.WithHelloWorldApp(func(appDir string) { 22 session := helpers.CustomCF(helpers.CFEnv{WorkingDirectory: appDir}, PushCommandName, appName, "--no-route") 23 Consistently(session).ShouldNot(Say(`Mapping routes\.\.\.`)) 24 Eventually(session).Should(Say(`name:\s+%s`, appName)) 25 Eventually(session).Should(Say(`requested state:\s+started`)) 26 Eventually(session).Should(Say(`(?m)routes:\s+\n`)) 27 Eventually(session).Should(Exit(0)) 28 }) 29 }) 30 })