-
Notifications
You must be signed in to change notification settings - Fork 95
Expand file tree
/
Copy pathautomatic-layering.e2e.ts
More file actions
36 lines (31 loc) · 1.2 KB
/
automatic-layering.e2e.ts
File metadata and controls
36 lines (31 loc) · 1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import { DOWNLOAD_TIMEOUT } from '@/wdio.shared.conf';
import { volViewPage } from '../pageobjects/volview.page';
import { FETUS_DATASET } from './configTestUtils';
import { writeManifestToFile } from './utils';
describe('Automatic Layering by File Name', () => {
it('should automatically layer files matching the layer extension pattern', async () => {
const config = {
io: {
layerExtension: 'layer',
},
};
const configFileName = 'automatic-layering-config.json';
await writeManifestToFile(config, configFileName);
await volViewPage.open(
`?config=[tmp/${configFileName}]&urls=[${FETUS_DATASET.url},${FETUS_DATASET.url}]&names=[base-image.mha,base-image.layer.mha]`
);
await volViewPage.waitForViews();
const renderTab = await volViewPage.renderingModuleTab;
await renderTab.click();
await browser.waitUntil(
async function layerSlidersExist() {
const layerOpacitySliders = await volViewPage.layerOpacitySliders;
return (await layerOpacitySliders.length) > 0;
},
{
timeout: DOWNLOAD_TIMEOUT,
timeoutMsg: `Expected at least one layer opacity slider to verify automatic layering`,
}
);
});
});