tests(Playwright): Full implementation of Page Object Models (POMs) to Playwright tests (#5608)
This commit is contained in:
1 parent
7b12dcf048
commit
d917e74e68
58 files changed
+1167
-496
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';
|
||||
|
||||
test.beforeEach(async ({ page }) => {
|
||||
const studyInstanceUID = '1.3.6.1.4.1.5962.99.1.2968617883.1314880426.1493322302363.3.0';
|
||||
@@ -7,9 +6,14 @@ test.beforeEach(async ({ page }) => {
|
||||
await visitStudy(page, studyInstanceUID, mode, 2000);
|
||||
});
|
||||
|
||||
test('should hydrate RT reports correctly', async ({ page }) => {
|
||||
await page.getByTestId('side-panel-header-right').click();
|
||||
await page.getByTestId('study-browser-thumbnail-no-image').dblclick();
|
||||
test('should hydrate RT reports correctly', async ({
|
||||
page,
|
||||
DOMOverlayPageObject,
|
||||
leftPanelPageObject,
|
||||
rightPanelPageObject,
|
||||
}) => {
|
||||
await rightPanelPageObject.toggle();
|
||||
await leftPanelPageObject.loadSeriesByModality('RTSTRUCT');
|
||||
|
||||
await checkForScreenshot(page, page, screenShotPaths.rtHydration2.rtPreHydration);
|
||||
// wait for 3 seconds
|
||||
@@ -34,9 +38,7 @@ test('should hydrate RT reports correctly', async ({ page }) => {
|
||||
|
||||
await page.waitForTimeout(3000);
|
||||
|
||||
//
|
||||
|
||||
// should preserve zoom and pan and scroll position after hydration
|
||||
await page.getByTestId('yes-hydrate-btn').click();
|
||||
await DOMOverlayPageObject.viewport.segmentationHydration.yes.click();
|
||||
await checkForScreenshot(page, page, screenShotPaths.rtHydration.rtPostHydration);
|
||||
});
|
||||
Reference in new issue
Block a user