Exemplo n.º 1
0
func createOrgPaginator(t *testing.T, reqs ...testnet.TestRequest) (ts *httptest.Server, handler *testnet.TestHandler, p *paginator.OrganizationPaginator) {
	ts, handler = testnet.NewTLSServer(t, reqs)

	config := &configuration.Configuration{
		AccessToken: "BEARER my_access_token",
		Target:      ts.URL,
	}
	gateway := net.NewCloudControllerGateway()
	p = paginator.NewOrganizationPaginator(config, gateway)
	return
}
Exemplo n.º 2
0
func (repo CloudControllerOrganizationRepository) Paginator() paginator.Paginator {
	return paginator.NewOrganizationPaginator(repo.config, repo.gateway)
}