. "github.com/cloudfoundry/cli/testhelpers/matchers" . "github.com/onsi/ginkgo" . "github.com/onsi/gomega" ) var _ = Describe("CreateAppManifest", func() { var ( ui *testterm.FakeUI configRepo coreconfig.Repository appSummaryRepo *apifakes.FakeAppSummaryRepository stackRepo *stacksfakes.FakeStackRepository cmd commandregistry.Command deps commandregistry.Dependency factory *requirementsfakes.FakeFactory flagContext flags.FlagContext loginRequirement requirements.Requirement targetedSpaceRequirement requirements.Requirement applicationRequirement *requirementsfakes.FakeApplicationRequirement fakeManifest *manifestfakes.FakeApp ) BeforeEach(func() { ui = &testterm.FakeUI{} configRepo = testconfig.NewRepositoryWithDefaults() appSummaryRepo = new(apifakes.FakeAppSummaryRepository) repoLocator := deps.RepoLocator.SetAppSummaryRepository(appSummaryRepo) stackRepo = new(stacksfakes.FakeStackRepository)
testreq "github.com/cloudfoundry/cli/testhelpers/requirements" testterm "github.com/cloudfoundry/cli/testhelpers/terminal" . "github.com/onsi/ginkgo" . "github.com/onsi/gomega" "github.com/cloudfoundry/cli/cf/commandregistry" "github.com/cloudfoundry/cli/cf/configuration/coreconfig" . "github.com/cloudfoundry/cli/testhelpers/matchers" ) var _ = Describe("stack command", func() { var ( ui *testterm.FakeUI config coreconfig.Repository repo *stacksfakes.FakeStackRepository requirementsFactory *testreq.FakeReqFactory deps commandregistry.Dependency ) updateCommandDependency := func(pluginCall bool) { deps.UI = ui deps.Config = config deps.RepoLocator = deps.RepoLocator.SetStackRepository(repo) commandregistry.Commands.SetCommand(commandregistry.Commands.FindCommand("stack").SetDependency(deps, pluginCall)) } BeforeEach(func() { ui = &testterm.FakeUI{} config = testconfig.NewRepositoryWithDefaults() requirementsFactory = &testreq.FakeReqFactory{LoginSuccess: true}
"github.com/cloudfoundry/cli/cf/requirements/requirementsfakes" testcmd "github.com/cloudfoundry/cli/testhelpers/commands" testconfig "github.com/cloudfoundry/cli/testhelpers/configuration" testterm "github.com/cloudfoundry/cli/testhelpers/terminal" . "github.com/onsi/ginkgo" . "github.com/onsi/gomega" "github.com/cloudfoundry/cli/cf/commands" . "github.com/cloudfoundry/cli/testhelpers/matchers" ) var _ = Describe("stacks command", func() { var ( ui *testterm.FakeUI repo *stacksfakes.FakeStackRepository config coreconfig.Repository requirementsFactory *requirementsfakes.FakeFactory deps commandregistry.Dependency ) updateCommandDependency := func(pluginCall bool) { deps.UI = ui deps.Config = config deps.RepoLocator = deps.RepoLocator.SetStackRepository(repo) commandregistry.Commands.SetCommand(commandregistry.Commands.FindCommand("stacks").SetDependency(deps, pluginCall)) } BeforeEach(func() { ui = &testterm.FakeUI{} config = testconfig.NewRepositoryWithDefaults() requirementsFactory = new(requirementsfakes.FakeFactory)
. "github.com/cloudfoundry/cli/testhelpers/matchers" . "github.com/onsi/ginkgo" . "github.com/onsi/gomega" ) var _ = Describe("App", func() { var ( ui *testterm.FakeUI appSummaryRepo *apifakes.FakeAppSummaryRepository appInstancesRepo *appinstancesfakes.FakeAppInstancesRepository stackRepo *stacksfakes.FakeStackRepository getAppModel *plugin_models.GetAppModel cmd commandregistry.Command deps commandregistry.Dependency factory *requirementsfakes.FakeFactory flagContext flags.FlagContext loginRequirement requirements.Requirement targetedSpaceRequirement requirements.Requirement applicationRequirement *requirementsfakes.FakeApplicationRequirement ) BeforeEach(func() { cmd = &application.ShowApp{} flagContext = flags.NewFlagContext(cmd.MetaData().Flags) ui = &testterm.FakeUI{} getAppModel = &plugin_models.GetAppModel{}