@@ -1322,7 +1322,7 @@ internal async Task<JObject> LoadAssemblyDynamicallyALCAndRunMethod(string asm_f
13221322 return await WaitFor ( Inspector . PAUSE ) ;
13231323 }
13241324
1325- internal async Task < JObject > LoadAssemblyAndTestHotReloadUsingSDBWithoutChanges ( string asm_file , string pdb_file , string class_name , string method_name , bool expectBpResolvedEvent )
1325+ internal async Task < JObject > LoadAssemblyAndTestHotReloadUsingSDBWithoutChanges ( string asm_file , string pdb_file , string class_name , string method_name , bool expectBpResolvedEvent , params string [ ] sourcesToWait )
13261326 {
13271327 byte [ ] bytes = File . ReadAllBytes ( asm_file ) ;
13281328 string asm_base64 = Convert . ToBase64String ( bytes ) ;
@@ -1338,7 +1338,7 @@ internal async Task<JObject> LoadAssemblyAndTestHotReloadUsingSDBWithoutChanges(
13381338
13391339 Task eventTask = expectBpResolvedEvent
13401340 ? WaitForBreakpointResolvedEvent ( )
1341- : WaitForScriptParsedEventsAsync ( "MethodBody0.cs" , "MethodBody1.cs" ) ;
1341+ : WaitForScriptParsedEventsAsync ( sourcesToWait ) ;
13421342 ( await cli . SendCommand ( "Runtime.evaluate" , load_assemblies , token ) ) . AssertOk ( ) ;
13431343 await eventTask ;
13441344
@@ -1397,7 +1397,7 @@ internal async Task<JObject> LoadAssemblyAndTestHotReloadUsingSDB(string asm_fil
13971397 return await WaitFor ( Inspector . PAUSE ) ;
13981398 }
13991399
1400- internal async Task < JObject > LoadAssemblyAndTestHotReload ( string asm_file , string pdb_file , string asm_file_hot_reload , string class_name , string method_name , bool expectBpResolvedEvent )
1400+ internal async Task < JObject > LoadAssemblyAndTestHotReload ( string asm_file , string pdb_file , string asm_file_hot_reload , string class_name , string method_name , bool expectBpResolvedEvent , string [ ] sourcesToWait , string methodName2 = "" , string methodName3 = "" )
14011401 {
14021402 byte [ ] bytes = File . ReadAllBytes ( asm_file ) ;
14031403 string asm_base64 = Convert . ToBase64String ( bytes ) ;
@@ -1434,13 +1434,18 @@ internal async Task<JObject> LoadAssemblyAndTestHotReload(string asm_file, strin
14341434
14351435 Task eventTask = expectBpResolvedEvent
14361436 ? WaitForBreakpointResolvedEvent ( )
1437- : WaitForScriptParsedEventsAsync ( "MethodBody0.cs" , "MethodBody1.cs" ) ;
1437+ : WaitForScriptParsedEventsAsync ( sourcesToWait ) ;
14381438 ( await cli . SendCommand ( "Runtime.evaluate" , load_assemblies , token ) ) . AssertOk ( ) ;
14391439 await eventTask ;
14401440
1441+ if ( methodName2 == "" )
1442+ methodName2 = method_name ;
1443+ if ( methodName3 == "" )
1444+ methodName3 = method_name ;
1445+
14411446 var run_method = JObject . FromObject ( new
14421447 {
1443- expression = "window.setTimeout(function() { invoke_static_method('[debugger-test] TestHotReload:RunMethod', '" + class_name + "', '" + method_name + "'); }, 1);"
1448+ expression = "window.setTimeout(function() { invoke_static_method('[debugger-test] TestHotReload:RunMethod', '" + class_name + "', '" + method_name + "', '" + methodName2 + "', '" + methodName3 + "' ); }, 1);"
14441449 } ) ;
14451450
14461451 await cli . SendCommand ( "Runtime.evaluate" , run_method , token ) ;
0 commit comments