feat: add агегку events

This commit is contained in:
2026-08-14 15:46:26 +03:00
parent 326fb67def
commit 34c2b79e27
10 changed files with 635 additions and 0 deletions
@@ -0,0 +1,14 @@
jest.mock('../prisma/prisma.service', () => ({
PrismaService: class PrismaService {},
}));
import { UpcomingEventsController } from './upcoming-events.controller';
describe('UpcomingEventsController', () => {
it('passes the authenticated user and account to the service', async () => {
const events = { get: jest.fn() };
const controller = new UpcomingEventsController(events as never);
await controller.get({ user: { sub: 'user' } } as never, 'account');
expect(events.get).toHaveBeenCalledWith('user', 'account');
});
});