@@ -11,6 +11,7 @@ const ciWorkflowPath = path.join(repoRoot, '.github/workflows/ci.yml');
1111const releaseMainWorkflowPath = path . join ( repoRoot , '.github/workflows/release-main.yml' ) ;
1212const releaseStableWorkflowPath = path . join ( repoRoot , '.github/workflows/release-stable.yml' ) ;
1313const releaseBetaWorkflowPath = path . join ( repoRoot , '.github/workflows/release-beta.yml' ) ;
14+ const releaseOnMainWorkflowPath = path . join ( repoRoot , '.github/workflows/release-on-main.yml' ) ;
1415const browserSmokeShellPath = path . join ( repoRoot , 'scripts/browser_smoke.sh' ) ;
1516const browserSmokeNodePath = path . join ( repoRoot , 'scripts/browser_smoke.mjs' ) ;
1617const pkgBuild = fs . readFileSync ( pkgBuildPath , 'utf8' ) ;
@@ -20,6 +21,7 @@ const ciWorkflow = fs.readFileSync(ciWorkflowPath, 'utf8');
2021const releaseMainWorkflow = fs . readFileSync ( releaseMainWorkflowPath , 'utf8' ) ;
2122const releaseStableWorkflow = fs . readFileSync ( releaseStableWorkflowPath , 'utf8' ) ;
2223const releaseBetaWorkflow = fs . readFileSync ( releaseBetaWorkflowPath , 'utf8' ) ;
24+ const releaseOnMainWorkflow = fs . readFileSync ( releaseOnMainWorkflowPath , 'utf8' ) ;
2325const browserSmokeShell = fs . readFileSync ( browserSmokeShellPath , 'utf8' ) ;
2426const browserSmokeNode = fs . readFileSync ( browserSmokeNodePath , 'utf8' ) ;
2527
@@ -91,10 +93,24 @@ test('browser smoke scripts are optional, URL-gated, and include core UI checks'
9193} ) ;
9294
9395test ( 'validation workflows include optional browser smoke integration' , ( ) => {
94- for ( const workflow of [ ciWorkflow , releaseMainWorkflow , releaseStableWorkflow , releaseBetaWorkflow ] ) {
96+ for ( const workflow of [ ciWorkflow , releaseMainWorkflow , releaseStableWorkflow , releaseBetaWorkflow , releaseOnMainWorkflow ] ) {
9597 assert . match ( workflow , / O p t i o n a l b r o w s e r s m o k e c h e c k s / ) ;
9698 assert . match ( workflow , / F V P L U S _ B R O W S E R _ S M O K E _ U R L / ) ;
9799 assert . match ( workflow , / b a s h s c r i p t s \/ b r o w s e r _ s m o k e \. s h / ) ;
98100 }
99101 assert . match ( releasePrepare , / b a s h s c r i p t s \/ b r o w s e r _ s m o k e \. s h / ) ;
100102} ) ;
103+
104+ test ( 'release-on-main workflow auto-publishes validated releases from current plg version' , ( ) => {
105+ assert . match ( releaseOnMainWorkflow , / n a m e : \s * R e l e a s e O n M a i n / ) ;
106+ assert . match ( releaseOnMainWorkflow , / p u s h : \s * \n \s * b r a n c h e s : \s * \n \s * - \s * m a i n / ) ;
107+ assert . match ( releaseOnMainWorkflow , / b a s h s c r i p t s \/ r e l e a s e _ g u a r d \. s h / ) ;
108+ assert . match ( releaseOnMainWorkflow , / b a s h s c r i p t s \/ i n s t a l l _ s m o k e \. s h / ) ;
109+ assert . match ( releaseOnMainWorkflow , / n o d e - - t e s t t e s t s \/ \* \. m j s / ) ;
110+ assert . match ( releaseOnMainWorkflow , / r e l e a s e _ n o t e s \. m d / ) ;
111+ assert . match ( releaseOnMainWorkflow , / f o l d e r v i e w \. p l u s \. p l g / ) ;
112+ assert . match ( releaseOnMainWorkflow , / a r c h i v e \/ f o l d e r v i e w \. p l u s - \$ \{ V E R S I O N \} \. t x z / ) ;
113+ assert . match ( releaseOnMainWorkflow , / g h r e l e a s e c r e a t e / ) ;
114+ assert . match ( releaseOnMainWorkflow , / g h r e l e a s e e d i t / ) ;
115+ assert . match ( releaseOnMainWorkflow , / G H _ T O K E N : \s * \$ \{ \{ \s * g i t h u b \. t o k e n \s * \} \} / ) ;
116+ } ) ;
0 commit comments