bigbluebutton-Github/bigbluebutton-html5/tests/puppeteer/webcam/share.js
Mohamed Amine Ben Salah 10a22d411e fixes webcams test
2020-03-26 16:51:41 -03:00

37 lines
926 B
JavaScript

const Page = require('../core/page');
const util = require('./util');
const params = require('../params');
class Share {
constructor() {
this.page1 = new Page();
this.page2 = new Page();
}
async init(meetingId) {
await this.page1.init(Page.getArgsWithVideo(), meetingId, { ...params, fullName: 'Streamer1' });
await this.page2.init(Page.getArgsWithVideo(), this.page1.meetingId, { ...params, fullName: 'Streamer2' });
}
async initPage(meetingId) {
await this.page1.init(Page.getArgsWithVideo(), meetingId, { ...params, fullName: 'Streamer1' });
}
async test() {
await util.enableWebcam(this.page1, this.page2);
const response = await util.evaluateCheck(this.page1, this.page2);
return response;
}
async closePage() {
await this.page1.close();
}
async close() {
await this.page1.close();
await this.page2.close();
}
}
module.exports = exports = Share;