本文整理汇总了Golang中github.com/cloudfoundry/cli/cf/api/space_quotas/fakes.FakeSpaceQuotaRepository.FindByGuidReturns方法的典型用法代码示例。如果您正苦于以下问题:Golang FakeSpaceQuotaRepository.FindByGuidReturns方法的具体用法?Golang FakeSpaceQuotaRepository.FindByGuidReturns怎么用?Golang FakeSpaceQuotaRepository.FindByGuidReturns使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类github.com/cloudfoundry/cli/cf/api/space_quotas/fakes.FakeSpaceQuotaRepository
的用法示例。
在下文中一共展示了FakeSpaceQuotaRepository.FindByGuidReturns方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。
示例1:
space.SpaceQuotaGuid = "runaway-guid"
quota := models.SpaceQuota{}
quota.Guid = "runaway-guid"
quota.Name = "runaway"
quota.MemoryLimit = 102400
quota.InstanceMemoryLimit = -1
quota.RoutesLimit = 111
quota.ServicesLimit = 222
quota.NonBasicServicesAllowed = false
requirementsFactory.LoginSuccess = true
requirementsFactory.TargetedOrgSuccess = true
requirementsFactory.Space = space
quotaRepo.FindByGuidReturns(quota, nil)
})
Context("when the space has a space quota", func() {
It("shows information about the given space", func() {
runCommand("whose-space-is-it-anyway")
Expect(ui.Outputs).To(ContainSubstrings(
[]string{"Getting info for space", "whose-space-is-it-anyway", "my-org", "my-user"},
[]string{"OK"},
[]string{"whose-space-is-it-anyway"},
[]string{"Org", "my-org"},
[]string{"Apps", "app1"},
[]string{"Domains", "domain1"},
[]string{"Services", "service1"},
[]string{"Security Groups", "Nacho Security", "Nacho Prime"},
[]string{"Space Quota", "runaway (100G memory limit, -1 instance memory limit, 111 routes, 222 services, paid services disallowed)"},