diff --git a/ci/config.ini b/ci/config.ini new file mode 100644 index 000000000000..82b96d9ef047 --- /dev/null +++ b/ci/config.ini @@ -0,0 +1,26 @@ +[Main] +# Enable the trace agent. +apm_enabled = true + +# trace-agent will use this hostname when reporting to the Datadog backend. +# default: stdout of `hostname` +hostname = myhost + +# trace-agent will use this api key when reporting to the Datadog backend. +# no default. +api_key = "api_key" + +# trace-agent will bind to this host when listening for traces +# additionally trace-agent expects dogstatsd to be bound to the same host +# for forwarding internal monitoring metrics +bind_host = 127.0.0.1 + +# trace-agent expects dogstatsd to be listening over UDP on this port +# this is where it will forward internal monitoring metrics +dogstatsd_port = 8125 + +# trace-agent will log it's output with this log level +log_level = INFO + +[trace.api] +endpoint = https://trace.agent.datadoghq.com diff --git a/ci/runtraceagent.ps1 b/ci/runtraceagent.ps1 new file mode 100644 index 000000000000..6e3fb70f8915 --- /dev/null +++ b/ci/runtraceagent.ps1 @@ -0,0 +1,3 @@ +# This script downloads the 5.19.0 version of the trace-agent and runs it in the background for the integration tests +Invoke-WebRequest https://github.com/DataDog/datadog-trace-agent/releases/download/5.19.0/trace-agent-windows-5.19.0.exe -OutFile trace-agent-windows.exe +Start-Process trace-agent-windows.exe "--ddconfig $PSScriptRoot\config.ini" diff --git a/src/Datadog.Trace.Tests.Net45/Datadog.Trace.Tests.Net45.csproj b/src/Datadog.Trace.Tests.Net45/Datadog.Trace.Tests.Net45.csproj index 2d2cd102d3bd..2a4351a8aa24 100644 --- a/src/Datadog.Trace.Tests.Net45/Datadog.Trace.Tests.Net45.csproj +++ b/src/Datadog.Trace.Tests.Net45/Datadog.Trace.Tests.Net45.csproj @@ -20,7 +20,7 @@ full false bin\Debug\ - DEBUG;TRACE + TRACE;DEBUG;NET45_TESTS prompt 4 @@ -28,7 +28,7 @@ pdbonly true bin\Release\ - TRACE + TRACE;NET45_TESTS prompt 4 diff --git a/src/Datadog.Trace.Tests/TracerTests.cs b/src/Datadog.Trace.Tests/TracerTests.cs index d5d658b7bffd..407dc32726fa 100644 --- a/src/Datadog.Trace.Tests/TracerTests.cs +++ b/src/Datadog.Trace.Tests/TracerTests.cs @@ -19,8 +19,10 @@ public void BuildSpan_NoParameter_DefaultParameters() var span = (Span)builder.Start(); #if NETCOREAPP2_0 Assert.Equal("testhost", span.ServiceName); -#else +#elif NET45_TESTS Assert.Equal("Datadog.Trace.Tests.Net45", span.ServiceName); +#else + Assert.Equal("Datadog.Trace.Tests", span.ServiceName); #endif Assert.Equal("Op1", span.OperationName); }