@@ -33,11 +33,13 @@ const themeRuntimeGuardPath = path.join(repoRoot, 'scripts/theme_runtime_guard.s
3333const perfBudgetGuardPath = path . join ( repoRoot , 'scripts/perf_budget_guard.sh' ) ;
3434const reproBuildGuardPath = path . join ( repoRoot , 'scripts/repro_build_guard.sh' ) ;
3535const mainBranchHistoryGuardPath = path . join ( repoRoot , 'scripts/main_branch_history_guard.sh' ) ;
36+ const devVersionBumpGuardPath = path . join ( repoRoot , 'scripts/dev_version_bump_guard.sh' ) ;
3637const pruneArchivesPath = path . join ( repoRoot , 'scripts/prune_archives.sh' ) ;
3738const unraidMatrixSmokePath = path . join ( repoRoot , 'scripts/unraid_matrix_smoke.sh' ) ;
3839const ensureChangesPath = path . join ( repoRoot , 'scripts/ensure_plg_changes_entry.sh' ) ;
3940const doctorPath = path . join ( repoRoot , 'scripts/doctor.sh' ) ;
4041const sharedLibPath = path . join ( repoRoot , 'scripts/lib.sh' ) ;
42+ const prePushHookPath = path . join ( repoRoot , '.githooks/pre-push' ) ;
4143const perfBaselinePath = path . join ( repoRoot , 'scripts/perf_baseline.json' ) ;
4244const pkgBuild = fs . readFileSync ( pkgBuildPath , 'utf8' ) ;
4345const stableTemplate = fs . readFileSync ( stableTemplatePath , 'utf8' ) ;
@@ -69,11 +71,13 @@ const themeRuntimeGuard = fs.readFileSync(themeRuntimeGuardPath, 'utf8');
6971const perfBudgetGuard = fs . readFileSync ( perfBudgetGuardPath , 'utf8' ) ;
7072const reproBuildGuard = fs . readFileSync ( reproBuildGuardPath , 'utf8' ) ;
7173const mainBranchHistoryGuard = fs . readFileSync ( mainBranchHistoryGuardPath , 'utf8' ) ;
74+ const devVersionBumpGuard = fs . readFileSync ( devVersionBumpGuardPath , 'utf8' ) ;
7275const pruneArchives = fs . readFileSync ( pruneArchivesPath , 'utf8' ) ;
7376const unraidMatrixSmoke = fs . readFileSync ( unraidMatrixSmokePath , 'utf8' ) ;
7477const ensureChanges = fs . readFileSync ( ensureChangesPath , 'utf8' ) ;
7578const doctorScript = fs . readFileSync ( doctorPath , 'utf8' ) ;
7679const sharedLib = fs . readFileSync ( sharedLibPath , 'utf8' ) ;
80+ const prePushHook = fs . readFileSync ( prePushHookPath , 'utf8' ) ;
7781const perfBaseline = JSON . parse ( fs . readFileSync ( perfBaselinePath , 'utf8' ) ) ;
7882
7983test ( 'pkg_build computes stable versions per current date only' , ( ) => {
@@ -208,6 +212,19 @@ test('remote publish guard validates raw manifest, archive, and checksum after p
208212 assert . match ( remotePublishGuard , / r e m o t e r a w m a n i f e s t , a r c h i v e , a n d c h e c k s u m m a t c h / ) ;
209213} ) ;
210214
215+ test ( 'dev pushes that change shipped plugin files must bump the manifest version' , ( ) => {
216+ assert . match ( devVersionBumpGuard , / T A R G E T _ B R A N C H = " \$ \( d e t e c t _ b r a n c h \) " / ) ;
217+ assert . match ( devVersionBumpGuard , / i f \[ \[ " \$ \{ T A R G E T _ B R A N C H \} " ! = " d e v " \] \] / ) ;
218+ assert . match ( devVersionBumpGuard , / F V P L U S _ D E V _ V E R S I O N _ B A S E _ R E F / ) ;
219+ assert . match ( devVersionBumpGuard , / f v p l u s : : r e a d _ p l g _ v e r s i o n " \$ \{ R O O T _ D I R \} \/ f o l d e r v i e w \. p l u s \. p l g " / ) ;
220+ assert . match ( devVersionBumpGuard , / g i t s h o w " \$ \{ r e f _ n a m e \} : f o l d e r v i e w \. p l u s \. p l g " / ) ;
221+ assert . match ( devVersionBumpGuard , / s r c \/ f o l d e r v i e w \. p l u s \/ \* | f o l d e r v i e w \. p l u s \. p l g | f o l d e r v i e w \. p l u s \. x m l / ) ;
222+ assert . match ( devVersionBumpGuard , / c h a n g e s h i p p e d p l u g i n f i l e s m u s t b u m p f o l d e r v i e w \. p l u s \. p l g v e r s i o n / ) ;
223+ assert . match ( devVersionBumpGuard , / b a s h s c r i p t s \/ r e l e a s e _ p r e p a r e \. s h ' o r ' b a s h p k g _ b u i l d \. s h / ) ;
224+ assert . match ( prePushHook , / e c h o " \[ p r e - p u s h \] R u n n i n g d e v v e r s i o n b u m p g u a r d \. \. \. " / ) ;
225+ assert . match ( prePushHook , / b a s h s c r i p t s \/ d e v _ v e r s i o n _ b u m p _ g u a r d \. s h / ) ;
226+ } ) ;
227+
211228test ( 'browser smoke scripts require folder editor coverage and include real editor interaction smoke' , ( ) => {
212229 assert . match ( browserSmokeShell , / F V P L U S _ B R O W S E R _ S M O K E _ U R L / ) ;
213230 assert . match ( browserSmokeShell , / F V P L U S _ B R O W S E R _ S M O K E _ R E Q U I R E D / ) ;
0 commit comments