Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed dependency from ConsoleExporter #1760

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion test/OpenTelemetry.Tests/OpenTelemetry.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
<ItemGroup>
<ProjectReference Include="$(RepoRoot)\src\OpenTelemetry\OpenTelemetry.csproj" />
<ProjectReference Include="$(RepoRoot)\src\OpenTelemetry.Exporter.InMemory\OpenTelemetry.Exporter.InMemory.csproj" />
<ProjectReference Include="..\..\src\OpenTelemetry.Exporter.Console\OpenTelemetry.Exporter.Console.csproj" />
</ItemGroup>

<ItemGroup Condition="'$(TargetFramework)' == 'netcoreapp2.1'">
Expand Down
13 changes: 5 additions & 8 deletions test/OpenTelemetry.Tests/Trace/ExportProcessorTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,11 @@
// limitations under the License.
// </copyright>

using System.Collections.Generic;
using System.Diagnostics;
using OpenTelemetry.Exporter;
using OpenTelemetry.Exporter.Console;
using OpenTelemetry.Trace;
using OpenTelemetry.Tests;
using Xunit;

namespace OpenTelemetry.Tests.Trace
namespace OpenTelemetry.Trace.Tests
cijothomas marked this conversation as resolved.
Show resolved Hide resolved
{
public class ExportProcessorTest
{
Expand All @@ -31,7 +28,7 @@ public class ExportProcessorTest
public void ExportProcessorIgnoresActivityWhenDropped()
{
var sampler = new AlwaysOffSampler();
var processor = new TestActivityExportProcessor(new ConsoleActivityExporter(null));
var processor = new TestActivityExportProcessor(new TestExporter<Activity>(_ => { }));
using var activitySource = new ActivitySource(ActivitySourceName);
using var sdk = Sdk.CreateTracerProviderBuilder()
.AddSource(ActivitySourceName)
Expand All @@ -52,7 +49,7 @@ public void ExportProcessorIgnoresActivityWhenDropped()
public void ExportProcessorIgnoresActivityMarkedAsRecordOnly()
{
var sampler = new RecordOnlySampler();
var processor = new TestActivityExportProcessor(new ConsoleActivityExporter(null));
var processor = new TestActivityExportProcessor(new TestExporter<Activity>(_ => { }));
using var activitySource = new ActivitySource(ActivitySourceName);
using var sdk = Sdk.CreateTracerProviderBuilder()
.AddSource(ActivitySourceName)
Expand All @@ -73,7 +70,7 @@ public void ExportProcessorIgnoresActivityMarkedAsRecordOnly()
public void ExportProcessorExportsActivityMarkedAsRecordAndSample()
{
var sampler = new AlwaysOnSampler();
var processor = new TestActivityExportProcessor(new ConsoleActivityExporter(null));
var processor = new TestActivityExportProcessor(new TestExporter<Activity>(_ => { }));
using var activitySource = new ActivitySource(ActivitySourceName);
using var sdk = Sdk.CreateTracerProviderBuilder()
.AddSource(ActivitySourceName)
Expand Down