Playwright/E2E: Add method to stub notification in Playwright and automate MM-T483 (#29203)

Этот коммит содержится в:
Saturnino Abril
2024-11-19 22:16:33 +08:00
коммит произвёл GitHub
родитель 05abb39019
Коммит 80289a0d8c
6 изменённых файлов: 176 добавлений и 2 удалений

Просмотреть файл

@@ -8,6 +8,7 @@ import {initSetup, getAdminClient} from './server';
import {hideDynamicChannelsContent, waitForAnimationEnd, waitUntil} from './test_action';
import {pages} from './ui/pages';
import {matchSnapshot} from './visual';
import {stubNotification, waitForNotification} from './mock_browser_api';
export {expect} from '@playwright/test';
@@ -41,7 +42,7 @@ export const test = base.extend<ExtendedFixtures>({
class PlaywrightExtended {
// ./browser_context
readonly testBrowser: TestBrowser;
readonly testBrowser;
// ./flag
readonly shouldHaveCallsEnabled;
@@ -65,6 +66,10 @@ class PlaywrightExtended {
// ./visual
readonly matchSnapshot;
// ./mock_browser_api
readonly stubNotification;
readonly waitForNotification;
constructor(browser: Browser) {
// ./browser_context
this.testBrowser = new TestBrowser(browser);
@@ -90,6 +95,10 @@ class PlaywrightExtended {
// ./visual
this.matchSnapshot = matchSnapshot;
// ./mock_browser_api
this.stubNotification = stubNotification;
this.waitForNotification = waitForNotification;
}
}