Documentation ¶
Index ¶
- type Client
- type Config
- type MockClient
- func (_m *MockClient) GetApplications(ctx context.Context) ([]v1.ApplicationSpec, error)
- func (_m *MockClient) GetClusters(ctx context.Context) ([]string, error)
- func (_m *MockClient) GetDashboards(ctx context.Context) ([]dashboardv1.DashboardSpec, error)
- func (_m *MockClient) GetName() string
- func (_m *MockClient) GetPlugins(ctx context.Context) ([]plugin.Instance, error)
- func (_m *MockClient) GetTeams(ctx context.Context) ([]teamv1.TeamSpec, error)
- func (_m *MockClient) GetUsers(ctx context.Context) ([]userv1.UserSpec, error)
- func (_m *MockClient) Proxy(w http.ResponseWriter, r *http.Request)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client interface { GetName() string GetPlugins(ctx context.Context) ([]plugin.Instance, error) GetClusters(ctx context.Context) ([]string, error) GetNamespaces(ctx context.Context) (map[string][]string, error) GetCRDs(ctx context.Context) ([]cluster.CRD, error) GetApplications(ctx context.Context) ([]applicationv1.ApplicationSpec, error) GetDashboards(ctx context.Context) ([]dashboardv1.DashboardSpec, error) GetTeams(ctx context.Context) ([]teamv1.TeamSpec, error) GetUsers(ctx context.Context) ([]userv1.UserSpec, error) GetResources(ctx context.Context, user *authContext.User, cluster, namespace, name, resource, path, paramName, param string) (map[string]any, error) Proxy(w http.ResponseWriter, r *http.Request) }
type MockClient ¶
MockClient is an autogenerated mock type for the Client type
func NewMockClient ¶
func NewMockClient(t testing.TB) *MockClient
NewMockClient creates a new instance of MockClient. It also registers the testing.TB interface on the mock and a cleanup function to assert the mocks expectations.
func (*MockClient) GetApplications ¶
func (_m *MockClient) GetApplications(ctx context.Context) ([]v1.ApplicationSpec, error)
GetApplications provides a mock function with given fields: ctx
func (*MockClient) GetClusters ¶
func (_m *MockClient) GetClusters(ctx context.Context) ([]string, error)
GetClusters provides a mock function with given fields: ctx
func (*MockClient) GetDashboards ¶
func (_m *MockClient) GetDashboards(ctx context.Context) ([]dashboardv1.DashboardSpec, error)
GetDashboards provides a mock function with given fields: ctx
func (*MockClient) GetName ¶
func (_m *MockClient) GetName() string
GetName provides a mock function with given fields:
func (*MockClient) GetPlugins ¶
GetPlugins provides a mock function with given fields: ctx
func (*MockClient) Proxy ¶
func (_m *MockClient) Proxy(w http.ResponseWriter, r *http.Request)
Proxy provides a mock function with given fields: w, r
Click to show internal directories.
Click to hide internal directories.