Open
Description
Branch: feature/interview-update
There are various cases when after adding or deleting calendars, some calendars are missing in the UserMeetingSettings record. Expected behaviour: each calendar should always have the next 5 fields:
id
<- calendar idaccountId
accountProvider
accessToken
isPrimary
Failed Cases
-
- User doesn't have UserMeetingSettings
- We add Microsoft calenadr
- There is not primary calendar from Nylas returned, so we use any writable calendar
Missing fields:
id
andisPrimary
flag, see screenshot -
- User has UserMeetingSettings with one Microsoft calendar from above without
id
andisPrimary
- We add Google calendar
- Microsoft calendar disappears and there is no
id
for google calendar, see screenshot - If after this we again connect Microsoft Calendar, then Google Calendar disappears, and there is no
id
, see screenshot
- User has UserMeetingSettings with one Microsoft calendar from above without
I guess most of these issues are because of the missing id
.
Task
Verify all these cases and make sure that we always have all 5 fields in all calendar records:
- User doesn't have UserMeetingSettings. Connect calendar which doesn't have
is_primary
at Nylas. - User doesn't have UserMeetingSettings. Connect calendar which has
is_primary
at Nylas. - User has UserMeetingSettings. Connect calendar which doesn't have
is_primary
at Nylas. - User has UserMeetingSettings. Connect calendar which has
is_primary
at Nylas. - Remove not last primary calendar, so another one become primary.
- Remove last primary calendar, so no calendars left.
- Any other case worth testing?