コード例 #1
0
ファイル: app_test.go プロジェクト: Reejoshi/cli
			err = cmd.Execute(flagContext)
		})

		It("gets the application summary", func() {
			Expect(err).NotTo(HaveOccurred())
			Expect(appSummaryRepo.GetSummaryCallCount()).To(Equal(1))
		})

		It("gets the app instances", func() {
			Expect(err).NotTo(HaveOccurred())
			Expect(appInstancesRepo.GetInstancesCallCount()).To(Equal(1))
		})

		It("gets the application from the application requirement", func() {
			Expect(err).NotTo(HaveOccurred())
			Expect(applicationRequirement.GetApplicationCallCount()).To(Equal(1))
		})

		It("prints a summary of the app", func() {
			Expect(err).NotTo(HaveOccurred())
			Expect(ui.Outputs()).To(ContainSubstrings(
				[]string{"Showing health and status for app fake-app-name"},
				[]string{"requested state: started"},
				[]string{"instances: 1/1"},
				// Commented to hide app-ports for release #117189491
				// []string{"app ports: 8080, 9090"},
				[]string{"usage: 1G x 1 instances"},
				[]string{"urls: fake-route-host.fake-route-domain-name"},
				[]string{"last uploaded: Thu Nov 19 01:00:15 UTC 2015"},
				[]string{"stack: fake-stack-name"},
				// buildpack tested separately