Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
xit('returns data', async () => {
const ctx = createTestContext();
const feedRecords = [
{
_id: '5b19146f65bbc725d2069082',
actionType: FeedActions.ENROLL,
courseId: 'course-id',
data: {},
dateTime: 0,
entityType: FeedEntities.User,
userId: 'apalchys',
},
] as IFeedRecordModel[];
mockingoose.User.toReturn({}, 'findOne');
mockingoose.FeedRecord.toReturn(feedRecords, 'find');
await getFeedRoute(ctx);
expect(ctx.status).toBe(200);
expect(ctx.body).toMatchSnapshot();
});