bigbluebutton-Github/bigbluebutton-tests/playwright/polling/polling.spec.js

92 lines
2.8 KiB
JavaScript
Raw Normal View History

2021-11-26 02:23:58 +08:00
const { test } = require('@playwright/test');
const { Polling } = require('./poll');
2022-01-20 03:50:59 +08:00
2023-04-28 20:30:29 +08:00
test.describe.serial('Polling', () => {
const polling = new Polling();
test.beforeAll(async ({ browser }) => {
const context = await browser.newContext();
const page = await context.newPage();
await polling.initModPage(page, true);
await polling.initUserPage(true, context);
});
2022-01-20 03:50:59 +08:00
2023-04-28 20:30:29 +08:00
// Manage
test('Create poll @ci', async () => {
await polling.createPoll();
});
2022-01-20 03:50:59 +08:00
2023-04-28 20:30:29 +08:00
test('Create anonymous poll @ci', async () => {
await polling.pollAnonymous();
});
2022-01-20 03:50:59 +08:00
2023-04-28 20:30:29 +08:00
test('Create quick poll - from the slide', async () => {
await polling.quickPoll();
});
2022-01-20 03:50:59 +08:00
2023-04-28 20:30:29 +08:00
test('Create poll with user response @ci', async () => {
await polling.pollUserResponse();
});
test('Stop a poll manually @ci', async () => {
await polling.stopPoll();
});
test('Manage response choices', async () => {
await polling.manageResponseChoices();
});
test('Not able to start new poll without presentation', async () => {
await polling.notAbleStartNewPollWithoutPresentation();
});
});
2022-10-26 04:12:59 +08:00
2023-04-28 20:30:29 +08:00
/*
test.describe.parallel('Polling', () => {
test.describe.parallel('Manage', () => {
2022-10-27 04:25:48 +08:00
test('Not able to start new poll without presentation', async ({ browser, context, page }) => {
2022-10-26 04:12:59 +08:00
const polling = new Polling(browser, context);
await polling.initPages(page);
2022-10-27 04:25:48 +08:00
await polling.notAbleStartNewPollWithoutPresentation();
2022-10-26 04:12:59 +08:00
});
test('Custom input', async ({ browser, context, page }) => {
const polling = new Polling(browser, context);
await polling.initPages(page);
await polling.customInput();
});
test('Allow multiple choices', async ({ browser, context, page }) => {
const polling = new Polling(browser, context);
await polling.initPages(page);
await polling.allowMultipleChoices();
});
2022-10-27 04:25:48 +08:00
test('Smart slides questions', async ({ browser, context, page }) => {
2022-10-26 04:12:59 +08:00
const polling = new Polling(browser, context);
await polling.initPages(page);
await polling.smartSlidesQuestions();
});
2022-01-20 03:50:59 +08:00
});
test.describe.parallel('Results', () => {
2022-06-08 02:52:22 +08:00
test('Poll results in chat message @ci', async ({ browser, context, page }) => {
2022-01-20 03:50:59 +08:00
const polling = new Polling(browser, context);
await polling.initPages(page);
await polling.pollResultsOnChat();
});
2022-06-08 02:52:22 +08:00
test('Poll results on whiteboard @ci', async ({ browser, page }) => {
2022-01-20 03:50:59 +08:00
const polling = new Polling(browser);
await polling.initModPage(page);
await polling.pollResultsOnWhiteboard();
});
test('Poll results in a different presentation', async ({ browser, page }) => {
const polling = new Polling(browser);
await polling.initModPage(page);
await polling.pollResultsInDifferentPresentation();
});
2021-11-26 02:23:58 +08:00
});
2021-12-04 01:01:36 +08:00
});
2023-04-28 20:30:29 +08:00
*/