Example #1
0
	"github.com/cloudfoundry/cli/cf/commands/routergroups"
	. "github.com/cloudfoundry/cli/testhelpers/matchers"
	. "github.com/onsi/ginkgo"
	. "github.com/onsi/gomega"
)

var _ = Describe("RouterGroups", func() {

	var (
		ui             *testterm.FakeUI
		routingAPIRepo *apifakes.FakeRoutingAPIRepository
		deps           commandregistry.Dependency
		cmd            *routergroups.RouterGroups
		flagContext    flags.FlagContext
		repoLocator    api.RepositoryLocator
		config         coreconfig.Repository

		requirementsFactory           *requirementsfakes.FakeFactory
		minAPIVersionRequirement      *requirementsfakes.FakeRequirement
		loginRequirement              *requirementsfakes.FakeRequirement
		routingAPIEndpoingRequirement *requirementsfakes.FakeRequirement
	)

	BeforeEach(func() {
		ui = new(testterm.FakeUI)
		routingAPIRepo = new(apifakes.FakeRoutingAPIRepository)
		config = testconfig.NewRepositoryWithDefaults()
		repoLocator = api.RepositoryLocator{}.SetRoutingAPIRepository(routingAPIRepo)
		deps = commandregistry.Dependency{
			UI:          ui,
			Config:      config,