tests(Playwright): Introduction of Page Object Models (POMs) to Playwright tests (#5557)

This commit is contained in:
Vinícius Alves de Faria Resende authored and GitHub committed 2025-11-20 09:29:14 -05:00
1 parent 1c991037ee
commit bdad2264ed
59 files changed
+1040 -756

No files matched your search

@@ -1,5 +1,4 @@
import { test } from 'playwright-test-coverage';
import { visitStudy, checkForScreenshot, screenShotPaths } from './utils';
import { checkForScreenshot, screenShotPaths, test, visitStudy } from './utils';
import { press } from './utils/keyboardUtils';
import { assertNumberOfModalityLoadBadges } from './utils/assertions';
@@ -11,10 +10,11 @@ test.beforeEach(async ({ page }) => {
test('should overlay an unhydrated SEG over a display set that the SEG does NOT reference', async ({
page,
viewportPageObject,
}) => {
await page.getByTestId('study-browser-thumbnail').nth(2).dblclick();
await page.getByTestId('dataOverlayMenu-default-btn').click();
await viewportPageObject.getById('default').overlayMenu.dataOverlay.click();
await page.getByTestId('AddSegmentationDataOverlay-default').click();
await page.getByText('SELECT A SEGMENTATION').click();
await page.getByTestId('T2 Weighted Axial Segmentations').click();
@@ -23,7 +23,7 @@ test('should overlay an unhydrated SEG over a display set that the SEG does NOT
assertNumberOfModalityLoadBadges({ page, expectedCount: 0 });
// Hide the overlay menu.
await page.getByTestId('dataOverlayMenu-default-btn').click();
await viewportPageObject.getById('default').overlayMenu.dataOverlay.click();
await page.waitForTimeout(5000);