Skip to content

Commit

Permalink
[PLATFORM-990]: Fix OTLP exporter failed to initialize error in test (p…
Browse files Browse the repository at this point in the history
  • Loading branch information
MaeIsBad authored Mar 3, 2023
1 parent 3b65abc commit 0ab8a9c
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions config/test.exs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import Config

config :opentelemetry,
tracer: :otel_tracer_default,
processors: [{:otel_batch_processor, %{scheduled_delay_ms: 1}}]
traces_exporter: :none,
processors: [{:otel_simple_processor, %{}}]
2 changes: 1 addition & 1 deletion test/instrumentation_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ defmodule OpentelemetryAbsintheTest.Instrumentation do
setup do
Application.delete_env(:opentelemetry_absinthe, :trace_options)
OpentelemetryAbsinthe.Instrumentation.teardown()
:otel_batch_processor.set_exporter(:otel_exporter_pid, self())
:otel_simple_processor.set_exporter(:otel_exporter_pid, self())
end

describe "trace configuration" do
Expand Down
1 change: 0 additions & 1 deletion test/test_helper.exs
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ defmodule AbsinthePlug.Test.Server do
plug(Absinthe.Plug, schema: AbsinthePlug.Test.Schema)
end

:otel_batch_processor.set_exporter(:otel_exporter_pid, self())
child_spec = [{Plug.Cowboy, scheme: :http, plug: AbsinthePlug.Test.Server, options: [port: 8000]}]
{:ok, _pid} = Supervisor.start_link(child_spec, strategy: :one_for_one)

Expand Down

0 comments on commit 0ab8a9c

Please sign in to comment.