File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -197,7 +197,7 @@ export class Registry {
197197 const parsedKey = parseRegistryKey ( key ) ;
198198 if ( parsedKey ?. dynamicActionHost ) {
199199 const hostId = `/dynamic-action-provider/${ parsedKey . dynamicActionHost } ` ;
200- const dap = await this . actionsById [ hostId ] ;
200+ const dap = await this . lookupAction ( hostId ) ;
201201 if ( ! dap || ! isDynamicActionProvider ( dap ) ) {
202202 return [ ] ;
203203 }
Original file line number Diff line number Diff line change @@ -634,4 +634,25 @@ describe('registry class', () => {
634634 ) ;
635635 } ) ;
636636 } ) ;
637+
638+ describe ( 'resolveActionNames' , ( ) => {
639+ it ( 'resolves dynamic actions from parent registry' , async ( ) => {
640+ const tool1 = action (
641+ { name : 'fs/tool1' , actionType : 'tool' } ,
642+ async ( ) => { }
643+ ) ;
644+ defineDynamicActionProvider ( registry , 'my-dap' , async ( ) => ( {
645+ tool : [ tool1 ] ,
646+ } ) ) ;
647+
648+ const childRegistry = new Registry ( registry ) ;
649+
650+ const resolved = await childRegistry . resolveActionNames (
651+ '/dynamic-action-provider/my-dap:tool/fs/tool1'
652+ ) ;
653+ assert . deepStrictEqual ( resolved , [
654+ '/dynamic-action-provider/my-dap:tool/fs/tool1' ,
655+ ] ) ;
656+ } ) ;
657+ } ) ;
637658} ) ;
You can’t perform that action at this time.
0 commit comments