File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 556556 "argType" : " number"
557557 }
558558 ]
559+ },
560+ {
561+ "name" : " load_memory_snapshot" ,
562+ "args" : [
563+ {
564+ "name" : " file_path_length" ,
565+ "argType" : " number"
566+ }
567+ ]
559568 }
560569]
Original file line number Diff line number Diff line change @@ -230,8 +230,12 @@ export type Context = Readonly<{
230230 ) : Promise <
231231 Record < string , DevTools . HeapSnapshotModel . HeapSnapshotModel . AggregatedInfo >
232232 > ;
233- getHeapSnapshotStats ( filePath : string ) : Promise < DevTools . HeapSnapshotModel . HeapSnapshotModel . Statistics > ;
234- getHeapSnapshotStaticData ( filePath : string ) : Promise < DevTools . HeapSnapshotModel . HeapSnapshotModel . StaticData | null > ;
233+ getHeapSnapshotStats (
234+ filePath : string ,
235+ ) : Promise < DevTools . HeapSnapshotModel . HeapSnapshotModel . Statistics > ;
236+ getHeapSnapshotStaticData (
237+ filePath : string ,
238+ ) : Promise < DevTools . HeapSnapshotModel . HeapSnapshotModel . StaticData | null > ;
235239} > ;
236240
237241export type ContextPage = Readonly < {
Original file line number Diff line number Diff line change @@ -43,8 +43,11 @@ describe('memory', () => {
4343 describe ( 'load_memory_snapshot' , ( ) => {
4444 it ( 'with default options' , async ( ) => {
4545 await withMcpContext ( async ( response , context ) => {
46- const filePath = join ( process . cwd ( ) , 'tests/fixtures/example.heapsnapshot' ) ;
47-
46+ const filePath = join (
47+ process . cwd ( ) ,
48+ 'tests/fixtures/example.heapsnapshot' ,
49+ ) ;
50+
4851 assert . ok ( existsSync ( filePath ) , `Fixture not found at ${ filePath } ` ) ;
4952
5053 await exploreMemorySnapshot . handler (
@@ -54,8 +57,13 @@ describe('memory', () => {
5457 ) ;
5558
5659 // Call handle to trigger formatting (similar to network tests)
57- const responseData = await response . handle ( exploreMemorySnapshot . name , context ) ;
58- const output = responseData . content . map ( c => ( c . type === 'text' ? c . text : '' ) ) . join ( '\n' ) ;
60+ const responseData = await response . handle (
61+ exploreMemorySnapshot . name ,
62+ context ,
63+ ) ;
64+ const output = responseData . content
65+ . map ( c => ( c . type === 'text' ? c . text : '' ) )
66+ . join ( '\n' ) ;
5967
6068 // Check if response contains Statistics or Static Data
6169 assert . ok ( output . includes ( 'Statistics:' ) ) ;
You can’t perform that action at this time.
0 commit comments