@@ -181,6 +181,44 @@ describe('CI task attribution through real Turborepo', () => {
181181 build : true ,
182182 } )
183183 } )
184+ it . each ( [
185+ [ 'apps/sim/public/library/example/cover.jpg' ] ,
186+ [ 'apps/sim/content/library/example/index.mdx' , 'apps/sim/public/library/example/cover.jpg' ] ,
187+ ] ) ( 'keeps library media on the rendering and SEO path: %j' , ( ...files ) => {
188+ const plan = classifyFiles ( files )
189+ expect ( plan . fallback ) . toBeUndefined ( )
190+ expect ( groups ( plan ) ) . toEqual ( [ 'seo' ] )
191+ expect ( plan . docsGroups ) . toEqual ( [ ] )
192+ expect ( plan . flags ) . toMatchObject ( {
193+ integration : false ,
194+ desktop_live : false ,
195+ production : false ,
196+ test_app : true ,
197+ build : true ,
198+ e2e_build : true ,
199+ } )
200+ } )
201+ it . each ( [ 'delete' , 'move' ] ) ( 'keeps SEO coverage when library media is removed: %s' , ( change ) => {
202+ const { repo } = fixture ( )
203+ const media = 'apps/sim/public/library/example/cover.jpg'
204+ write ( repo , media , 'fixture media' )
205+ git ( repo , 'add' , '-A' )
206+ git ( repo , 'commit' , '--quiet' , '-m' , 'media base' )
207+ const base = git ( repo , 'rev-parse' , 'HEAD' )
208+ if ( change === 'delete' ) git ( repo , 'rm' , media )
209+ else git ( repo , 'mv' , media , 'apps/sim/public/library/example/renamed.jpg' )
210+ git ( repo , 'commit' , '--quiet' , '-m' , change )
211+ const plan = classify ( repo , base )
212+ expect ( plan . fallback ) . toBeUndefined ( )
213+ expect ( groups ( plan ) ) . toEqual ( [ 'seo' ] )
214+ expect ( plan . flags ) . toMatchObject ( {
215+ build : true ,
216+ e2e_build : true ,
217+ integration : false ,
218+ desktop_live : false ,
219+ docs : false ,
220+ } )
221+ } )
184222 it . each ( [
185223 'apps/sim/app/workspace/[workspaceId]/upgrade/components/comparison-table/comparison-data.ts' ,
186224 'apps/sim/providers/models.ts' ,
@@ -344,15 +382,15 @@ describe('CI task attribution through real Turborepo', () => {
344382 build : true ,
345383 } )
346384 } )
347- it ( 'keeps unknown app modules and non-code fixtures in the shared runtime boundary' , ( ) => {
348- for ( const path of [
349- 'apps/sim/new-domain/feature.ts ' ,
350- 'apps/sim/tools/service/__fixtures__/README.md ' ,
351- ] ) {
352- const plan = classifyFiles ( [ path ] )
353- expect ( plan . fallback ) . toBeUndefined ( )
354- expect ( plan . flags ) . toMatchObject ( { integration : true , desktop_live : true , e2e_build : true } )
355- }
385+ it . each ( [
386+ 'apps/sim/new-domain/feature.ts' ,
387+ 'apps/sim/public/ new-domain/config.json ' ,
388+ 'apps/sim/public/favicon/favicon.ico ' ,
389+ 'apps/sim/tools/service/__fixtures__/README.md' ,
390+ ] ) ( 'keeps unclassified runtime files in the shared boundary: %s' , ( path ) => {
391+ const plan = classifyFiles ( [ path ] )
392+ expect ( plan . fallback ) . toBeUndefined ( )
393+ expect ( plan . flags ) . toMatchObject ( { integration : true , desktop_live : true , e2e_build : true } )
356394 } )
357395 it . each ( [
358396 '.github/workflows/checks.yml' ,
0 commit comments