mirror of
https://github.com/immich-app/immich
synced 2026-08-22 13:13:05 +00:00
fix one e2e test
This commit is contained in:
parent
1d030594c6
commit
eb35bfb306
2 changed files with 14 additions and 3 deletions
|
|
@ -1,12 +1,13 @@
|
|||
import {
|
||||
addAssetsToAlbum,
|
||||
AlbumResponseDto,
|
||||
AlbumUserRole,
|
||||
AssetFileUploadResponseDto,
|
||||
AssetOrder,
|
||||
LoginResponseDto,
|
||||
SharedLinkType,
|
||||
addAssetsToAlbum,
|
||||
deleteUser,
|
||||
getAlbumInfo,
|
||||
LoginResponseDto,
|
||||
SharedLinkType,
|
||||
} from '@immich/sdk';
|
||||
import { createUserDto, uuidDto } from 'src/fixtures';
|
||||
import { errorDto } from 'src/responses';
|
||||
|
|
@ -78,6 +79,12 @@ describe('/album', () => {
|
|||
}),
|
||||
]);
|
||||
|
||||
await utils.updateAlbumUser(user2.accessToken, {
|
||||
id: albums[3].id,
|
||||
userId: user1.userId,
|
||||
updateAlbumUserDto: { role: AlbumUserRole.Editor },
|
||||
});
|
||||
|
||||
await addAssetsToAlbum(
|
||||
{ id: albums[3].id, bulkIdsDto: { ids: [user1Asset1.id] } },
|
||||
{ headers: asBearerAuth(user1.accessToken) },
|
||||
|
|
|
|||
|
|
@ -26,6 +26,7 @@ import {
|
|||
searchMetadata,
|
||||
setAdminOnboarding,
|
||||
signUpAdmin,
|
||||
updateAlbumUser,
|
||||
updateConfig,
|
||||
validate,
|
||||
} from '@immich/sdk';
|
||||
|
|
@ -281,6 +282,9 @@ export const utils = {
|
|||
createAlbum: (accessToken: string, dto: CreateAlbumDto) =>
|
||||
createAlbum({ createAlbumDto: dto }, { headers: asBearerAuth(accessToken) }),
|
||||
|
||||
updateAlbumUser: (accessToken: string, args: Parameters<typeof updateAlbumUser>[0]) =>
|
||||
updateAlbumUser(args, { headers: asBearerAuth(accessToken) }),
|
||||
|
||||
createAsset: async (
|
||||
accessToken: string,
|
||||
dto?: Partial<Omit<CreateAssetDto, 'assetData'>> & { assetData?: AssetData },
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue