@@ -13,13 +13,16 @@ const liveReportValidatorPath =
1313 "packages/scripts/validate-capability-router-live-reports.ts" ;
1414const liveReportValidatorSelfTestPath =
1515 "packages/scripts/validate-capability-router-live-reports.self-test.ts" ;
16+ const githubLiveArtifactValidatorPath =
17+ "packages/scripts/validate-capability-router-github-live-artifacts.ts" ;
1618
1719type Check = {
1820 name : string ;
1921 pattern : RegExp ;
2022 source ?:
2123 | "agent-package"
2224 | "endpoint-conformance"
25+ | "github-live-artifact-validator"
2326 | "live-report-validator"
2427 | "live-report-validator-self-test"
2528 | "live-report-writer"
@@ -117,7 +120,7 @@ export const checks: Check[] = [
117120 {
118121 name : "GitHub live artifact validator downloads and validates reports" ,
119122 pattern :
120- / g h [ \s \S ] * r u n [ \s \S ] * d o w n l o a d [ \s \S ] * r e m o t e - c a p a b i l i t y - c l o u d - l i v e - r e p o r t [ \s \S ] * r e m o t e - c a p a b i l i t y - p r o v i d e r - l i v e - r e p o r t [ \s \S ] * t e s t : r e m o t e - c a p a b i l i t i e s : v a l i d a t e - l i v e - r e p o r t s [ \s \S ] * - - k i n d [ \s \S ] * c l o u d [ \s \S ] * t e s t : r e m o t e - c a p a b i l i t i e s : v a l i d a t e - l i v e - r e p o r t s [ \s \S ] * - - k i n d [ \s \S ] * p r o v i d e r [ \s \S ] * - - r e q u i r e - p r o v i d e r s [ \s \S ] * e 2 b , h o m e - m a c h i n e , m o b i l e - c o m p a n i o n / ,
123+ / C L O U D _ A R T I F A C T \s * = \s * " r e m o t e - c a p a b i l i t y - c l o u d - l i v e - r e p o r t " [ \s \S ] * P R O V I D E R _ A R T I F A C T \s * = \s * " r e m o t e - c a p a b i l i t y - p r o v i d e r - l i v e - r e p o r t " [ \s \S ] * r u n C o m m a n d \( " g h " [ \s \S ] * " r u n " [ \s \S ] * " d o w n l o a d " [ \s \S ] * C L O U D _ A R T I F A C T [ \s \S ] * P R O V I D E R _ A R T I F A C T [ \s \S ] * t e s t : r e m o t e - c a p a b i l i t i e s : v a l i d a t e - l i v e - r e p o r t s [ \s \S ] * - - k i n d [ \s \S ] * c l o u d [ \s \S ] * t e s t : r e m o t e - c a p a b i l i t i e s : v a l i d a t e - l i v e - r e p o r t s [ \s \S ] * - - k i n d [ \s \S ] * p r o v i d e r [ \s \S ] * - - r e q u i r e - p r o v i d e r s [ \s \S ] * e 2 b , h o m e - m a c h i n e , m o b i l e - c o m p a n i o n / ,
121124 source : "github-live-artifact-validator" ,
122125 message :
123126 "GitHub live artifact validation must download both artifacts and validate Cloud plus required provider report contents." ,
@@ -381,6 +384,7 @@ export function validateCapabilityRouterLiveCi(
381384 options : {
382385 agentPackageJson ?: string ;
383386 endpointConformanceSource ?: string ;
387+ githubLiveArtifactValidatorSource ?: string ;
384388 liveReportValidatorSelfTestSource ?: string ;
385389 providerSmokeSource ?: string ;
386390 rootPackageJson ?: string ;
@@ -409,6 +413,7 @@ function getCheckContent(
409413 options : {
410414 agentPackageJson ?: string ;
411415 endpointConformanceSource ?: string ;
416+ githubLiveArtifactValidatorSource ?: string ;
412417 liveReportValidatorSelfTestSource ?: string ;
413418 providerSmokeSource ?: string ;
414419 rootPackageJson ?: string ;
@@ -420,6 +425,9 @@ function getCheckContent(
420425 if ( check . source === "endpoint-conformance" ) {
421426 return options . endpointConformanceSource ?? "" ;
422427 }
428+ if ( check . source === "github-live-artifact-validator" ) {
429+ return options . githubLiveArtifactValidatorSource ?? "" ;
430+ }
423431 if ( check . source === "live-report-validator" ) {
424432 return options . liveReportValidatorSource ?? "" ;
425433 }
@@ -439,6 +447,9 @@ function getCheckContent(
439447function getCheckSourcePath ( check : Check , workflowPath : string ) : string {
440448 if ( check . source === "agent-package" ) return agentPackagePath ;
441449 if ( check . source === "endpoint-conformance" ) return endpointConformancePath ;
450+ if ( check . source === "github-live-artifact-validator" ) {
451+ return githubLiveArtifactValidatorPath ;
452+ }
442453 if ( check . source === "live-report-validator" ) return liveReportValidatorPath ;
443454 if ( check . source === "live-report-validator-self-test" ) {
444455 return liveReportValidatorSelfTestPath ;
@@ -462,11 +473,16 @@ if (import.meta.main) {
462473 liveReportValidatorSelfTestPath ,
463474 "utf8" ,
464475 ) ;
476+ const githubLiveArtifactValidatorSource = readFileSync (
477+ githubLiveArtifactValidatorPath ,
478+ "utf8" ,
479+ ) ;
465480 const liveReportWriterSource = readFileSync ( liveReportWriterPath , "utf8" ) ;
466481 const providerSmokeSource = readFileSync ( providerSmokePath , "utf8" ) ;
467482 const failures = validateCapabilityRouterLiveCi ( workflow , {
468483 agentPackageJson,
469484 endpointConformanceSource,
485+ githubLiveArtifactValidatorSource,
470486 liveReportValidatorSelfTestSource,
471487 liveReportValidatorSource,
472488 liveReportWriterSource,
0 commit comments