mirror of
https://github.com/Art051/immich.git
synced 2025-08-11 19:29:00 +00:00
feat(web): show partners assets on the main timeline (#4933)
This commit is contained in:
@@ -1,11 +1,11 @@
|
||||
import { BadRequestException } from '@nestjs/common';
|
||||
import { authStub, newPartnerRepositoryMock, partnerStub } from '@test';
|
||||
import { UserResponseDto } from '../index';
|
||||
import { IPartnerRepository, PartnerDirection } from '../repositories';
|
||||
import { IAccessRepository, IPartnerRepository, PartnerDirection } from '../repositories';
|
||||
import { PartnerResponseDto } from './partner.dto';
|
||||
import { PartnerService } from './partner.service';
|
||||
|
||||
const responseDto = {
|
||||
admin: <UserResponseDto>{
|
||||
admin: <PartnerResponseDto>{
|
||||
email: 'admin@test.com',
|
||||
firstName: 'admin_first_name',
|
||||
id: 'admin_id',
|
||||
@@ -20,8 +20,9 @@ const responseDto = {
|
||||
updatedAt: new Date('2021-01-01'),
|
||||
externalPath: null,
|
||||
memoriesEnabled: true,
|
||||
inTimeline: true,
|
||||
},
|
||||
user1: <UserResponseDto>{
|
||||
user1: <PartnerResponseDto>{
|
||||
email: 'immich@test.com',
|
||||
firstName: 'immich_first_name',
|
||||
id: 'user-id',
|
||||
@@ -36,16 +37,18 @@ const responseDto = {
|
||||
updatedAt: new Date('2021-01-01'),
|
||||
externalPath: null,
|
||||
memoriesEnabled: true,
|
||||
inTimeline: true,
|
||||
},
|
||||
};
|
||||
|
||||
describe(PartnerService.name, () => {
|
||||
let sut: PartnerService;
|
||||
let partnerMock: jest.Mocked<IPartnerRepository>;
|
||||
let accessMock: jest.Mocked<IAccessRepository>;
|
||||
|
||||
beforeEach(async () => {
|
||||
partnerMock = newPartnerRepositoryMock();
|
||||
sut = new PartnerService(partnerMock);
|
||||
sut = new PartnerService(partnerMock, accessMock);
|
||||
});
|
||||
|
||||
it('should work', () => {
|
||||
|
||||
Reference in New Issue
Block a user