Skip to content

Commit b4fcbea

Browse files
committed
vp test: test if video is playing on ESM highlights graph page
1 parent 26011bf commit b4fcbea

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import { vpTest } from '../../fixtures/vpTest';
2+
import { ExampleLinkName } from '../../testData/ExampleLinkNames';
3+
import { getEsmLinkByName } from '../../testData/esmPageLinksData';
4+
import { test } from '@playwright/test';
5+
import { waitForPageToLoadWithTimeout } from '../../src/helpers/waitForPageToLoadWithTimeout';
6+
import { ESM_URL } from '../../testData/esmUrl';
7+
8+
const link = getEsmLinkByName(ExampleLinkName.HighlightsGraph);
9+
vpTest(`Test if video on ESM highlights graph page is playing as expected`, async ({ page, pomPages }) => {
10+
await test.step('Navigate to ESM highlights graph page by clicking on link', async () => {
11+
await page.goto(ESM_URL);
12+
await pomPages.mainPage.clickLinkByName(link.name);
13+
await waitForPageToLoadWithTimeout(page, 5000);
14+
});
15+
await test.step('Click on play button of video player to play video', async () => {
16+
return pomPages.highlightGraphPage.videoHighlightsGraphPage.clickPlay();
17+
});
18+
await test.step('Validating that the video is playing', async () => {
19+
await pomPages.highlightGraphPage.videoHighlightsGraphPage.validateVideoIsPlaying(true);
20+
});
21+
});

0 commit comments

Comments
 (0)