1
0
mirror of https://github.com/immich-app/immich.git synced 2025-01-11 06:10:28 +02:00
immich/server/test/api/library-api.ts

11 lines
362 B
TypeScript
Raw Normal View History

import { LibraryResponseDto } from '@app/domain';
import request from 'supertest';
export const libraryApi = {
getAll: async (server: any, accessToken: string) => {
const { body, status } = await request(server).get(`/library/`).set('Authorization', `Bearer ${accessToken}`);
expect(status).toBe(200);
return body as LibraryResponseDto[];
},
};