@@ -185,16 +185,15 @@ public sealed class OverloadTests
185185 Trace-Command - Name MethodInvocation - Expression {
186186 $obj.GenericMethod [int ]()
187187 } - FilePath $filePath
188- # FUTURE: The underlying mechanism should be improved here
189- Get-Content $filePath | Should - BeLike " *Invoking method: void GenericMethod()"
188+ Get-Content $filePath | Should - BeLike " *Invoking method: void GenericMethod`` [int`` ]()"
190189 }
191190
192191 It " Traces generic method with argument" {
193192 $obj = [TraceCommandTests.OverloadTests ]::new()
194193 Trace-Command - Name MethodInvocation - Expression {
195194 $obj.GenericMethodWithArg (" foo" )
196195 } - FilePath $filePath
197- Get-Content $filePath | Should - BeLike " *Invoking method: string GenericMethodWithArg(string obj)"
196+ Get-Content $filePath | Should - BeLike " *Invoking method: string GenericMethodWithArg`` [string `` ] (string obj)"
198197 }
199198
200199 It " Traces .NET call with default value" {
@@ -239,14 +238,14 @@ public sealed class OverloadTests
239238 }
240239 } - FilePath $filePath
241240 # type fqn is used, the wildcard avoids hardcoding that
242- Get-Content $filePath | Should - BeLike " *Invoking method: static int SizeOf(System.RuntimeType, * structure)"
241+ Get-Content $filePath | Should - BeLike " *Invoking method: static int SizeOf`` [System.RuntimeType, * `` ] (System.RuntimeType, * structure)"
243242 }
244243
245244 It " Traces LINQ call" {
246245 Trace-Command - Name MethodInvocation - Expression {
247246 [System.Linq.Enumerable ]::Union([int []]@ (1 , 2 ), [int []]@ (3 , 4 ))
248247 } - FilePath $filePath
249- Get-Content $filePath | Should - BeLike " *Invoking method: static System.Collections.Generic.IEnumerable`` [int`` ] Union(System.Collections.Generic.IEnumerable`` [int`` ] first, System.Collections.Generic.IEnumerable`` [int`` ] second)"
248+ Get-Content $filePath | Should - BeLike " *Invoking method: static System.Collections.Generic.IEnumerable`` [int`` ] Union`` [int `` ] (System.Collections.Generic.IEnumerable`` [int`` ] first, System.Collections.Generic.IEnumerable`` [int`` ] second)"
250249 }
251250 }
252251
0 commit comments