@@ -48,6 +48,8 @@ const isWindows = os.platform() === 'win32';
4848const containerFilePath = path . resolve ( __dirname , '..' , 'resources' , 'bootable-containerfile' ) ;
4949const contextDirectory = path . resolve ( __dirname , '..' , 'resources' ) ;
5050const skipInstallation = process . env . SKIP_INSTALLATION ;
51+ const buildISOImage = process . env . BUILD_ISO_IMAGE ;
52+ let timeoutForBuild = 600000 ;
5153
5254beforeEach < RunnerTestContext > ( async ctx => {
5355 ctx . pdRunner = pdRunner ;
@@ -124,9 +126,18 @@ describe('BootC Extension', async () => {
124126 await playExpect . poll ( async ( ) => await imagesPage . waitForImageExists ( imageName ) ) . toBeTruthy ( ) ;
125127 } , 150000 ) ;
126128
127- test . skipIf ( isLinux ) . each ( [ 'QCOW2' , 'AMI' , 'RAW' , 'VMDK' , 'ISO' ] ) (
128- `Building bootable image type: %s` ,
129- async type => {
129+ describe . skipIf ( isLinux ) . each ( [ 'QCOW2' , 'AMI' , 'RAW' , 'VMDK' , 'ISO' ] ) ( 'Building images ' , async type => {
130+ test ( `Building bootable image type: ${ type } ` , async context => {
131+ if ( type === 'ISO' ) {
132+ if ( buildISOImage ) {
133+ timeoutForBuild = 1200000 ;
134+ console . log ( `Building ISO image requested, extending timeout to ${ timeoutForBuild } ` ) ;
135+ } else {
136+ console . log ( `Building ISO image not requested, skipping test` ) ;
137+ context . skip ( ) ;
138+ }
139+ }
140+
130141 const imagesPage = await navBar . openImages ( ) ;
131142 await playExpect ( imagesPage . heading ) . toBeVisible ( ) ;
132143
@@ -136,7 +147,13 @@ describe('BootC Extension', async () => {
136147 const pathToStore = path . resolve ( __dirname , '..' , 'tests' , 'output' , 'images' , `${ type } -${ architecture } ` ) ;
137148 [ page , webview ] = await handleWebview ( ) ;
138149 const bootcPage = new BootcPage ( page , webview ) ;
139- const result = await bootcPage . buildDiskImage ( `${ imageName } :${ imageTag } ` , pathToStore , type , architecture ) ;
150+ const result = await bootcPage . buildDiskImage (
151+ `${ imageName } :${ imageTag } ` ,
152+ pathToStore ,
153+ type ,
154+ architecture ,
155+ timeoutForBuild ,
156+ ) ;
140157 console . log (
141158 `Building disk image for platform ${ os . platform ( ) } and architecture ${ architecture } and type ${ type } is ${ result } ` ,
142159 ) ;
@@ -147,9 +164,8 @@ describe('BootC Extension', async () => {
147164 console . log ( 'Expected to pass on Linux, Windows and macOS' ) ;
148165 playExpect ( result ) . toBeTruthy ( ) ;
149166 }
150- } ,
151- 620000 ,
152- ) ;
167+ } , 1250000 ) ;
168+ } ) ;
153169 } ,
154170 ) ;
155171
0 commit comments