@@ -239,7 +239,9 @@ export default class Maestro extends BaseProvider<MaestroOptions> {
239239 const { allFlowFiles, baseDir } = flowResult ;
240240 const effectiveBase =
241241 baseDir || this . computeCommonDirectory ( allFlowFiles ) ;
242- logger . info ( 'Zip structure (files as they will appear in the archive):' ) ;
242+ logger . info (
243+ 'Zip structure (files as they will appear in the archive):' ,
244+ ) ;
243245 for ( const file of allFlowFiles ) {
244246 const archiveName = path . relative ( effectiveBase , path . resolve ( file ) ) ;
245247 logger . info ( ` ${ archiveName } ` ) ;
@@ -470,10 +472,7 @@ export default class Maestro extends BaseProvider<MaestroOptions> {
470472 if ( flowsPaths . length === 1 ) {
471473 const singlePath = flowsPaths [ 0 ] ;
472474 const stat = await fs . promises . stat ( singlePath ) . catch ( ( ) => null ) ;
473- if (
474- stat ?. isFile ( ) &&
475- path . extname ( singlePath ) . toLowerCase ( ) === '.zip'
476- ) {
475+ if ( stat ?. isFile ( ) && path . extname ( singlePath ) . toLowerCase ( ) === '.zip' ) {
477476 return null ;
478477 }
479478 }
@@ -543,9 +542,7 @@ export default class Maestro extends BaseProvider<MaestroOptions> {
543542 baseDir = projectRoot . dir ;
544543 // Include config.yaml and discover its dependencies
545544 const configResolved = path . resolve ( projectRoot . configPath ) ;
546- if (
547- ! allFlowFiles . some ( ( f ) => path . resolve ( f ) === configResolved )
548- ) {
545+ if ( ! allFlowFiles . some ( ( f ) => path . resolve ( f ) === configResolved ) ) {
549546 allFlowFiles . push ( projectRoot . configPath ) ;
550547 }
551548 }
@@ -835,10 +832,7 @@ export default class Maestro extends BaseProvider<MaestroOptions> {
835832 ) : Promise < { includeTags ?: string [ ] ; excludeTags ?: string [ ] } > {
836833 const candidates = this . options . configFile
837834 ? [ path . resolve ( this . options . configFile ) ]
838- : [
839- path . join ( baseDir , 'config.yaml' ) ,
840- path . join ( baseDir , 'config.yml' ) ,
841- ] ;
835+ : [ path . join ( baseDir , 'config.yaml' ) , path . join ( baseDir , 'config.yml' ) ] ;
842836
843837 for ( const candidate of candidates ) {
844838 try {
@@ -2128,8 +2122,24 @@ export default class Maestro extends BaseProvider<MaestroOptions> {
21282122
21292123 for ( const run of runs ) {
21302124 try {
2131- const reportEndpoint =
2132- reportFormat === 'junit' ? 'junit_report' : 'html_report' ;
2125+ let reportEndpoint : string ;
2126+ let reportKey : string ;
2127+ switch ( reportFormat ) {
2128+ case 'junit' :
2129+ reportEndpoint = 'junit_report' ;
2130+ reportKey = 'junit_report' ;
2131+ break ;
2132+ case 'html-detailed' :
2133+ reportEndpoint = 'html_report_detailed' ;
2134+ reportKey = 'html_report_detailed' ;
2135+ break ;
2136+ case 'html' :
2137+ default :
2138+ reportEndpoint = 'html_report' ;
2139+ reportKey = 'html_report' ;
2140+ break ;
2141+ }
2142+
21332143 const response = await axios . get (
21342144 `${ this . URL } /${ this . appId } /${ run . id } /${ reportEndpoint } ` ,
21352145 {
@@ -2149,8 +2159,6 @@ export default class Maestro extends BaseProvider<MaestroOptions> {
21492159 utils . checkForUpdate ( latestVersion ) ;
21502160
21512161 // Extract the report content from the JSON response
2152- const reportKey =
2153- reportFormat === 'junit' ? 'junit_report' : 'html_report' ;
21542162 const reportContent = response . data [ reportKey ] ;
21552163
21562164 if ( ! reportContent ) {
0 commit comments