-
Notifications
You must be signed in to change notification settings - Fork 135
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
integration test refactor, support SqlClient on .NET Core (#113)
* refactor DynamicMethodBuilder.CreateMethodCallDelegate() to get the parameter and return types from the delegate type * restore the stylecop suppression I removed earlier because it's stupid * refactor integration tests to further use the TestHelper as a base class * clean up code * add support for "DD_" prefixes in environment variables (we should phase out "DATADOG_" soon) * cast to CommandBehavior * taking stylecop down a notch * handle instance methods in DynamicMethodBuilder * use DynamicMethodBuilder for SqlServer integration, intercept ExecuteReader(CommandBehavior) * fix Core MVC integration * only output standard output or standard error is there is any text * cache the delegate for the dynamically generated method * inline small CreateDelegate()
- Loading branch information
1 parent
e930392
commit adf6bf4
Showing
12 changed files
with
179 additions
and
104 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
test/Datadog.Trace.ClrProfiler.IntegrationTests/ProcessResult.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
using System; | ||
using System.Diagnostics; | ||
|
||
namespace Datadog.Trace.ClrProfiler.IntegrationTests | ||
{ | ||
public class ProcessResult : IDisposable | ||
{ | ||
public ProcessResult( | ||
Process process, | ||
string standardOutput, | ||
string standardError, | ||
int exitCode) | ||
{ | ||
Process = process; | ||
StandardOutput = standardOutput; | ||
StandardError = standardError; | ||
ExitCode = exitCode; | ||
} | ||
|
||
public Process Process { get; } | ||
|
||
public string StandardOutput { get; } | ||
|
||
public string StandardError { get; } | ||
|
||
public int ExitCode { get; } | ||
|
||
public void Dispose() | ||
{ | ||
Process?.Dispose(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.