fix: ohif tests to run with cornerstone 3d 5.0 (#6043)
* chore(tests): Update multiple screenshot test images for various specs * feat(screenshot-reviewer): Add screenshot review tool and update package.json scripts * fix(DICOMSRDisplayTool): Improve actor presence check in viewport * chore(tests): Update multiple screenshot assets for various specs * chore(tests): Integrate waitForPaintToSettle and waitForViewportsRendered in multiple specs for improved rendering stability * chore(tests): Update screenshot assets for SEGHydration and SEGNoHydration specs * test: update progressive loading screenshots * jest 30 test fixes for compatibility with pnpm cs3d * Use correct setDisplaySets instead of setDataId * fix: Naming change for LegacyVolumeViewport3D * Update to allow tolerance for contour tests * update * fix * refactor: Replace instanceof checks with utility functions for viewport type validation * fix: Update createSegmentationForViewport to handle undefined displaySetInstanceUID gracefully * bun lock * fix: Install cs3d with pnpm instead of bun * Update node version for playwright * Update to v5.0.0 of cs3d * fix: Build dependency * audit * Change to a web await retry assert * Fix timing related test failures * fix: Freehand close --------- Co-authored-by: Bill Wallace <wayfarer3130@gmail.com>
This commit is contained in:
1 parent
a27f779f0b
commit
6dd150d401
172 files changed
+3081
-1866
No files matched your search
+42
-14
@@ -126,8 +126,9 @@ test.describe('Crosshairs Test', async () => {
|
||||
await viewportPageObject.crosshairs.axial.rotate();
|
||||
await viewportPageObject.crosshairs.sagittal.rotate();
|
||||
await viewportPageObject.crosshairs.coronal.rotate();
|
||||
const afterRotate = await getCrosshairsSignature(page);
|
||||
expect(afterRotate).not.toEqual(beforeRotate);
|
||||
await expect
|
||||
.poll(() => getCrosshairsSignature(page), { timeout: CROSSHAIRS_DOM_TIMEOUT_MS })
|
||||
.not.toEqual(beforeRotate);
|
||||
});
|
||||
|
||||
test('should allow the user to adjust the slab thickness', async ({
|
||||
@@ -143,8 +144,9 @@ test.describe('Crosshairs Test', async () => {
|
||||
await viewportPageObject.crosshairs.axial.increase();
|
||||
await viewportPageObject.crosshairs.sagittal.increase();
|
||||
await viewportPageObject.crosshairs.coronal.increase();
|
||||
const afterIncrease = await getLayerSignature(page, 'svg-layer-mpr-axial');
|
||||
expect(afterIncrease).not.toEqual(beforeIncrease);
|
||||
await expect
|
||||
.poll(() => getLayerSignature(page, 'svg-layer-mpr-axial'), { timeout: CROSSHAIRS_DOM_TIMEOUT_MS })
|
||||
.not.toEqual(beforeIncrease);
|
||||
});
|
||||
|
||||
test('should reset the crosshairs to the initial position when reset is clicked', async ({
|
||||
@@ -160,14 +162,27 @@ test.describe('Crosshairs Test', async () => {
|
||||
await viewportPageObject.crosshairs.axial.rotate();
|
||||
await viewportPageObject.crosshairs.sagittal.rotate();
|
||||
await viewportPageObject.crosshairs.coronal.rotate();
|
||||
const rotatedPosition = await getCrosshairsSignature(page);
|
||||
expect(rotatedPosition).not.toEqual(initialPosition);
|
||||
await expect
|
||||
.poll(() => getCrosshairsSignature(page), { timeout: CROSSHAIRS_DOM_TIMEOUT_MS })
|
||||
.not.toEqual(initialPosition);
|
||||
|
||||
await mainToolbarPageObject.moreTools.reset.click();
|
||||
await expectCrosshairsReady(page);
|
||||
expect(await areLayerLinesAxisAligned(page, 'svg-layer-mpr-axial')).toBeTruthy();
|
||||
expect(await areLayerLinesAxisAligned(page, 'svg-layer-mpr-sagittal')).toBeTruthy();
|
||||
expect(await areLayerLinesAxisAligned(page, 'svg-layer-mpr-coronal')).toBeTruthy();
|
||||
await expect
|
||||
.poll(() => areLayerLinesAxisAligned(page, 'svg-layer-mpr-axial'), {
|
||||
timeout: CROSSHAIRS_DOM_TIMEOUT_MS,
|
||||
})
|
||||
.toBe(true);
|
||||
await expect
|
||||
.poll(() => areLayerLinesAxisAligned(page, 'svg-layer-mpr-sagittal'), {
|
||||
timeout: CROSSHAIRS_DOM_TIMEOUT_MS,
|
||||
})
|
||||
.toBe(true);
|
||||
await expect
|
||||
.poll(() => areLayerLinesAxisAligned(page, 'svg-layer-mpr-coronal'), {
|
||||
timeout: CROSSHAIRS_DOM_TIMEOUT_MS,
|
||||
})
|
||||
.toBe(true);
|
||||
});
|
||||
|
||||
test('should reset the crosshairs when a new displayset is loaded', async ({
|
||||
@@ -184,13 +199,26 @@ test.describe('Crosshairs Test', async () => {
|
||||
await viewportPageObject.crosshairs.axial.rotate();
|
||||
await viewportPageObject.crosshairs.sagittal.rotate();
|
||||
await viewportPageObject.crosshairs.coronal.rotate();
|
||||
const rotatedPosition = await getCrosshairsSignature(page);
|
||||
expect(rotatedPosition).not.toEqual(initialPosition);
|
||||
await expect
|
||||
.poll(() => getCrosshairsSignature(page), { timeout: CROSSHAIRS_DOM_TIMEOUT_MS })
|
||||
.not.toEqual(initialPosition);
|
||||
|
||||
await leftPanelPageObject.loadSeriesByDescription('Recon 3: LIVER 3 PHASE (AP)');
|
||||
await expectCrosshairsReady(page);
|
||||
expect(await areLayerLinesAxisAligned(page, 'svg-layer-mpr-axial')).toBeTruthy();
|
||||
expect(await areLayerLinesAxisAligned(page, 'svg-layer-mpr-sagittal')).toBeTruthy();
|
||||
expect(await areLayerLinesAxisAligned(page, 'svg-layer-mpr-coronal')).toBeTruthy();
|
||||
await expect
|
||||
.poll(() => areLayerLinesAxisAligned(page, 'svg-layer-mpr-axial'), {
|
||||
timeout: CROSSHAIRS_DOM_TIMEOUT_MS,
|
||||
})
|
||||
.toBe(true);
|
||||
await expect
|
||||
.poll(() => areLayerLinesAxisAligned(page, 'svg-layer-mpr-sagittal'), {
|
||||
timeout: CROSSHAIRS_DOM_TIMEOUT_MS,
|
||||
})
|
||||
.toBe(true);
|
||||
await expect
|
||||
.poll(() => areLayerLinesAxisAligned(page, 'svg-layer-mpr-coronal'), {
|
||||
timeout: CROSSHAIRS_DOM_TIMEOUT_MS,
|
||||
})
|
||||
.toBe(true);
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user