2019-08-30 12:34:51 +01:00
|
|
|
// Copyright (C) 2019 Storj Labs, Inc.
|
|
|
|
// See LICENSE for copying information.
|
|
|
|
|
|
|
|
import { ProjectMemberCursor, ProjectMembersApi, ProjectMembersPage } from '@/types/projectMembers';
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Mock for ProjectMembersApi
|
|
|
|
*/
|
|
|
|
export class ProjectMembersApiMock implements ProjectMembersApi {
|
|
|
|
public cursor: ProjectMemberCursor;
|
|
|
|
public page: ProjectMembersPage;
|
|
|
|
|
|
|
|
public setMockPage(page: ProjectMembersPage): void {
|
|
|
|
this.page = page;
|
|
|
|
}
|
|
|
|
|
2021-08-05 12:07:45 +01:00
|
|
|
add(_projectId: string, _emails: string[]): Promise<void> {
|
2019-08-30 12:34:51 +01:00
|
|
|
throw new Error('not implemented');
|
|
|
|
}
|
|
|
|
|
2021-08-05 12:07:45 +01:00
|
|
|
delete(_projectId: string, _emails: string[]): Promise<void> {
|
2019-08-30 12:34:51 +01:00
|
|
|
throw new Error('not implemented');
|
|
|
|
}
|
|
|
|
|
2021-08-05 12:07:45 +01:00
|
|
|
get(_projectId: string, _cursor: ProjectMemberCursor): Promise<ProjectMembersPage> {
|
2019-08-30 12:34:51 +01:00
|
|
|
return Promise.resolve(this.page);
|
|
|
|
}
|
|
|
|
}
|