diff --git a/src/MeetingsAdapter.js b/src/MeetingsAdapter.js index 4de2849..40cd14f 100644 --- a/src/MeetingsAdapter.js +++ b/src/MeetingsAdapter.js @@ -118,6 +118,19 @@ export default class MeetingsAdapter extends WebexAdapter { return throwError(new Error('getMeeting(ID) must be defined in MeetingsAdapter')); } + /** + * Joins the meeting of the given ID. + * Joining a meeting is performed as a side-effect and this method does not + * return a value. Instead, joining a meeting should trigger getMeeting to + * emit a new updated Meeting object. + * + * @param {string} ID ID of the meeting to join. + * @memberof MeetingsAdapter + */ + joinMeeting(ID) { + throw new Error('joinMeeting(ID) must be defined in MeetingsAdapter'); + } + /** * Retrieves the local device media (video/audio) and adds them to the meeting * with the some default media settings. diff --git a/src/MeetingsAdapter.test.js b/src/MeetingsAdapter.test.js index 3f7a73e..9ec6fb5 100644 --- a/src/MeetingsAdapter.test.js +++ b/src/MeetingsAdapter.test.js @@ -45,6 +45,16 @@ describe('Meetings Adapter Interface', () => { }); }); + describe('joinMeeting()', () => { + test('errors because it needs to be defined', () => { + try { + meetingsAdapter.joinMeeting('meetingID'); + } catch (error) { + expect(error.message).toBe('joinMeeting(ID) must be defined in MeetingsAdapter'); + } + }); + }); + describe('addLocalMedia()', () => { test('errors because it needs to be defined', () => { try {