@@ -333,37 +333,48 @@ describe('agent, skill and tool names held per namespace, on a booted showcase',
333333 expect ( await metaAt ( 'tool' , TOOL , 'com.qa.bare.alpha' ) ) . toEqual ( [ 'com.qa.bare.alpha' , 'alpha tool' ] ) ;
334334 } ) ;
335335
336- it ( 'CONTROL — install-local of a package declaring fresh agent, skill and tool names installs, and every AI door serves it' , async ( ) => {
337- const { status, body } = await installLocal ( inline ( 'epsilon' , {
338- agents : [ agent ( 'epsilon' , 'epsilon_agent' ) ] ,
339- skills : [ skill ( 'epsilon' , 'epsilon_skill' ) ] ,
340- tools : [ tool ( 'epsilon' , 'epsilon_tool' ) ] ,
341- } ) ) ;
342- expect ( status , JSON . stringify ( body ) ) . toBeLessThan ( 300 ) ;
343- expect ( await packageIds ( ) ) . toContain ( 'com.qa.bare.epsilon' ) ;
344- expect ( await metaPackage ( 'agent' , 'epsilon_agent' ) ) . toBe ( 'com.qa.bare.epsilon' ) ;
345- expect ( await metaPackage ( 'skill' , 'epsilon_skill' ) ) . toBe ( 'com.qa.bare.epsilon' ) ;
346- expect ( await metaPackage ( 'tool' , 'epsilon_tool' ) ) . toBe ( 'com.qa.bare.epsilon' ) ;
347- expect ( await promptText ( 'epsilon-epsilon_skill' ) ) . toContain ( 'epsilon skill instructions' ) ;
348- expect ( await promptText ( 'epsilon_skill' ) , 'one holder: the bare name still answers' ) . toContain ( 'epsilon skill instructions' ) ;
336+ // The install is SETUP (loading), so it runs in a hook and the `it` times only the reads it judges.
337+ describe ( 'CONTROL — install-local of a package declaring fresh agent, skill and tool names' , ( ) => {
338+ beforeAll ( async ( ) => {
339+ const { status, body } = await installLocal ( inline ( 'epsilon' , {
340+ agents : [ agent ( 'epsilon' , 'epsilon_agent' ) ] ,
341+ skills : [ skill ( 'epsilon' , 'epsilon_skill' ) ] ,
342+ tools : [ tool ( 'epsilon' , 'epsilon_tool' ) ] ,
343+ } ) ) ;
344+ expect ( status , JSON . stringify ( body ) ) . toBeLessThan ( 300 ) ;
345+ } , 60_000 ) ;
346+
347+ it ( 'installs, and every AI door serves it' , async ( ) => {
348+ expect ( await packageIds ( ) ) . toContain ( 'com.qa.bare.epsilon' ) ;
349+ expect ( await metaPackage ( 'agent' , 'epsilon_agent' ) ) . toBe ( 'com.qa.bare.epsilon' ) ;
350+ expect ( await metaPackage ( 'skill' , 'epsilon_skill' ) ) . toBe ( 'com.qa.bare.epsilon' ) ;
351+ expect ( await metaPackage ( 'tool' , 'epsilon_tool' ) ) . toBe ( 'com.qa.bare.epsilon' ) ;
352+ expect ( await promptText ( 'epsilon-epsilon_skill' ) ) . toContain ( 'epsilon skill instructions' ) ;
353+ expect ( await promptText ( 'epsilon_skill' ) , 'one holder: the bare name still answers' ) . toContain ( 'epsilon skill instructions' ) ;
354+ } ) ;
349355 } ) ;
350356
351- it ( '[#31701, #31985] install-local of a package of a THIRD namespace declaring the held agent, skill and tool names installs; the bare read then names all three holders' , async ( ) => {
352- const { status, body } = await installLocal ( inline ( 'gamma' , { agents : [ agent ( 'gamma' ) ] , skills : [ skill ( 'gamma' ) ] , tools : [ tool ( 'gamma' ) ] } ) ) ;
353- expect ( status , JSON . stringify ( body ) ) . toBeLessThan ( 300 ) ;
354- expect ( await packageIds ( ) ) . toContain ( 'com.qa.bare.gamma' ) ;
355- expect ( await metaAt ( 'agent' , AGENT , 'com.qa.bare.gamma' ) ) . toEqual ( [ 'com.qa.bare.gamma' , 'gamma agent' ] ) ;
356- expect ( await metaAt ( 'skill' , SKILL , 'com.qa.bare.gamma' ) ) . toEqual ( [ 'com.qa.bare.gamma' , 'gamma skill' ] ) ;
357- expect ( await metaAt ( 'tool' , TOOL , 'com.qa.bare.gamma' ) ) . toEqual ( [ 'com.qa.bare.gamma' , 'gamma tool' ] ) ;
358- const all = [ 'com.qa.bare.alpha' , 'com.qa.bare.beta' , 'com.qa.bare.gamma' ] ;
359- await expectMetaRefused ( 'agent' , AGENT , all ) ;
360- await expectMetaRefused ( 'skill' , SKILL , all ) ;
361- await expectMetaRefused ( 'tool' , TOOL , all ) ;
362- expect ( await metaAt ( 'tool' , TOOL , 'com.qa.bare.alpha' ) ) . toEqual ( [ 'com.qa.bare.alpha' , 'alpha tool' ] ) ;
363- // The first packages' items are unchanged.
364- expect ( await metaAt ( 'agent' , AGENT , 'com.qa.bare.alpha' ) ) . toEqual ( [ 'com.qa.bare.alpha' , 'alpha agent' ] ) ;
365- expect ( await promptText ( `alpha-${ SKILL } ` ) ) . toContain ( 'alpha skill instructions' ) ;
366- expect ( await promptText ( `gamma-${ SKILL } ` ) ) . toContain ( 'gamma skill instructions' ) ;
357+ describe ( '[#31701, #31985] install-local of a package of a THIRD namespace declaring the held agent, skill and tool names' , ( ) => {
358+ beforeAll ( async ( ) => {
359+ const { status, body } = await installLocal ( inline ( 'gamma' , { agents : [ agent ( 'gamma' ) ] , skills : [ skill ( 'gamma' ) ] , tools : [ tool ( 'gamma' ) ] } ) ) ;
360+ expect ( status , JSON . stringify ( body ) ) . toBeLessThan ( 300 ) ;
361+ } , 60_000 ) ;
362+
363+ it ( 'installs; the bare read then names all three holders' , async ( ) => {
364+ expect ( await packageIds ( ) ) . toContain ( 'com.qa.bare.gamma' ) ;
365+ expect ( await metaAt ( 'agent' , AGENT , 'com.qa.bare.gamma' ) ) . toEqual ( [ 'com.qa.bare.gamma' , 'gamma agent' ] ) ;
366+ expect ( await metaAt ( 'skill' , SKILL , 'com.qa.bare.gamma' ) ) . toEqual ( [ 'com.qa.bare.gamma' , 'gamma skill' ] ) ;
367+ expect ( await metaAt ( 'tool' , TOOL , 'com.qa.bare.gamma' ) ) . toEqual ( [ 'com.qa.bare.gamma' , 'gamma tool' ] ) ;
368+ const all = [ 'com.qa.bare.alpha' , 'com.qa.bare.beta' , 'com.qa.bare.gamma' ] ;
369+ await expectMetaRefused ( 'agent' , AGENT , all ) ;
370+ await expectMetaRefused ( 'skill' , SKILL , all ) ;
371+ await expectMetaRefused ( 'tool' , TOOL , all ) ;
372+ expect ( await metaAt ( 'tool' , TOOL , 'com.qa.bare.alpha' ) ) . toEqual ( [ 'com.qa.bare.alpha' , 'alpha tool' ] ) ;
373+ // The first packages' items are unchanged.
374+ expect ( await metaAt ( 'agent' , AGENT , 'com.qa.bare.alpha' ) ) . toEqual ( [ 'com.qa.bare.alpha' , 'alpha agent' ] ) ;
375+ expect ( await promptText ( `alpha-${ SKILL } ` ) ) . toContain ( 'alpha skill instructions' ) ;
376+ expect ( await promptText ( `gamma-${ SKILL } ` ) ) . toContain ( 'gamma skill instructions' ) ;
377+ } ) ;
367378 } ) ;
368379
369380 /**
0 commit comments