bigbluebutton-Github/bigbluebutton-tests/playwright/polling/polling.spec.js
Anton Barboza de Sá 6564659750
test: All param tests on ci (#20878)
* test: all param tests on ci

* test: remove check for notification on parameter test

* test: remove 'Force restore presentation on new poll result' test - keep only one using the parameter -, fix selector and add all necessary assertions for the cases when the presentation should be restored

* test: enable param test in CI

* test: update tests tagging
2024-08-23 14:32:58 -03:00

73 lines
2.2 KiB
JavaScript

const { test } = require('../fixtures');
const { fullyParallel } = require('../playwright.config');
const { Polling } = require('./poll');
const { initializePages } = require('../core/helpers');
const { encodeCustomParams } = require('../parameters/util');
const { PARAMETER_HIDE_PRESENTATION_TOAST } = require('../core/constants');
const hidePresentationToast = encodeCustomParams(PARAMETER_HIDE_PRESENTATION_TOAST);
test.describe('Polling', { tag: '@ci' }, async () => {
const polling = new Polling();
test.describe.configure({ mode: fullyParallel ? 'parallel' : 'serial' });
test[fullyParallel ? 'beforeEach' : 'beforeAll'](async ({ browser }) => {
await initializePages(polling, browser, { isMultiUser: true, joinParameter: hidePresentationToast });
});
// Manage
test('Create poll', async () => {
await polling.createPoll();
});
test('Create anonymous poll', async () => {
await polling.pollAnonymous();
});
test('Create quick poll - from the slide', async () => {
await polling.quickPoll();
});
test('Create poll with user response', async () => {
await polling.pollUserResponse();
});
test('Stop a poll manually', 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();
});
test('Custom input', async () => {
await polling.customInput();
});
test('Allow multiple choices', async () => {
await polling.allowMultipleChoices();
});
test('Smart slides questions', async () => {
await polling.smartSlidesQuestions();
});
// Results
test('Poll results in chat message', async () => {
await polling.pollResultsOnChat();
});
test('Poll results on whiteboard', { tag: '@flaky' } , async () => {
await polling.pollResultsOnWhiteboard();
});
test('Poll results in a different presentation', async ({}, testInfo) => {
test.fixme(!testInfo.config.fullyParallel, 'Currently only works in parallel mode. Poll results not being displayed in the presentation');
await polling.pollResultsInDifferentPresentation();
});
});