Skip to content
This repository was archived by the owner on Mar 16, 2024. It is now read-only.

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix mock client
Browse files Browse the repository at this point in the history
sosodev committed Jan 3, 2024
1 parent 4e65dd8 commit 3af910d
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions pkg/cli/testdata/MockClient.go
Original file line number Diff line number Diff line change
@@ -8,10 +8,12 @@ import (
"github.com/acorn-io/baaah/pkg/typed"
apiv1 "github.com/acorn-io/runtime/pkg/apis/api.acorn.io/v1"
v1 "github.com/acorn-io/runtime/pkg/apis/internal.acorn.io/v1"
snapshotv1 "github.com/acorn-io/runtime/pkg/apis/snapshot.storage.k8s.io/v1"
"github.com/acorn-io/runtime/pkg/client"
"github.com/acorn-io/runtime/pkg/client/term"
"github.com/acorn-io/runtime/pkg/labels"
"github.com/acorn-io/runtime/pkg/project"
corev1 "k8s.io/api/core/v1"
apierrors "k8s.io/apimachinery/pkg/api/errors"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/runtime/schema"
@@ -147,6 +149,31 @@ type MockClient struct {
EventItem *apiv1.Event
}

func (m *MockClient) SnapshotCreate(ctx context.Context, pvc *corev1.PersistentVolumeClaim) (*snapshotv1.VolumeSnapshot, error) {
//TODO implement me
panic("implement me")
}

func (m *MockClient) SnapshotList(ctx context.Context) ([]snapshotv1.VolumeSnapshot, error) {
//TODO implement me
panic("implement me")
}

func (m *MockClient) SnapshotGet(ctx context.Context, name string) (*snapshotv1.VolumeSnapshot, error) {
//TODO implement me
panic("implement me")
}

func (m *MockClient) SnapshotDelete(ctx context.Context, name string) error {
//TODO implement me
panic("implement me")
}

func (m *MockClient) SnapshotRestore(ctx context.Context, snapshotName string, volumeName string) error {
//TODO implement me
panic("implement me")
}

func (m *MockClient) KubeConfig(ctx context.Context, opts *client.KubeProxyAddressOptions) ([]byte, error) {
//TODO implement me
panic("implement me")

0 comments on commit 3af910d

Please sign in to comment.