Skip to content

Commit

Permalink
Support profiling Pester with CC using Profiler v3.1 or v4 (#2321)
Browse files Browse the repository at this point in the history
  • Loading branch information
fflaten committed Apr 3, 2023
1 parent 887ccee commit 36b3164
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/csharp/Pester/Tracing/CodeCoverageTracer.cs
Expand Up @@ -102,5 +102,13 @@ public void Trace(string message, IScriptExtent extent, ScriptBlock _, int __)

lineColumn[key2] = points;
}

#pragma warning disable IDE0060
// Profiler v3.1 compatible overload
public void Trace(IScriptExtent extent, ScriptBlock _, int __) => Trace(null, extent, _, __);

// Profiler v4 compatible overload
public void Trace(IScriptExtent extent, ScriptBlock _, int __, string ___, string ____) => Trace(null, extent, _, __);
#pragma warning restore IDE0060
}
}

0 comments on commit 36b3164

Please sign in to comment.