feat: add Drone CI pipelines, Jest unit tests, and Prettier check
Some checks failed
continuous-integration/drone/push Build encountered an error
Some checks failed
continuous-integration/drone/push Build encountered an error
Add Drone CI with server build/test and format check pipelines. Add unit tests for password utils and recurrenceExpander. Add check_format script, fix Jest config to ignore dist/, remove dead CaldavService.test.ts, apply Prettier formatting.
This commit is contained in:
@@ -40,7 +40,10 @@ export class EventController {
|
||||
await this.pushToCaldav(userId, event);
|
||||
res.status(201).json(event);
|
||||
} catch (error) {
|
||||
log.error({ err: error, userId: req.user?.userId }, "Error creating event");
|
||||
log.error(
|
||||
{ err: error, userId: req.user?.userId },
|
||||
"Error creating event",
|
||||
);
|
||||
res.status(500).json({ error: "Failed to create event" });
|
||||
}
|
||||
}
|
||||
@@ -67,7 +70,10 @@ export class EventController {
|
||||
const events = await this.eventService.getAll(req.user!.userId);
|
||||
res.json(events);
|
||||
} catch (error) {
|
||||
log.error({ err: error, userId: req.user?.userId }, "Error getting events");
|
||||
log.error(
|
||||
{ err: error, userId: req.user?.userId },
|
||||
"Error getting events",
|
||||
);
|
||||
res.status(500).json({ error: "Failed to get events" });
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user