Loading spec/support/tracing/rails/shared_examples.rb +9 −2 Original line number Diff line number Diff line Loading @@ -45,7 +45,7 @@ RSpec.shared_examples "a tracing instrumenter" do expected_tags.each do |name, value| expect(fake_span).to receive(:set_tag).with(name, value) end allow(fake_span).to receive(:set_tag).with("error", true) allow(fake_span).to receive(:set_tag) allow(fake_span).to receive(:log_kv) allow(fake_scope).to receive(:close) Loading @@ -54,7 +54,14 @@ RSpec.shared_examples "a tracing instrumenter" do end it "logs an exception on the span" do # ... allow(fake_span).to receive(:set_tag) expect(fake_span).to receive(:set_tag).with("error", true) expect(fake_span).to receive(:log_kv) allow(fake_scope).to receive(:close) instrumenter.finish("event name", "id", payload.merge(exception: StandardError.new)) end end end Loading
spec/support/tracing/rails/shared_examples.rb +9 −2 Original line number Diff line number Diff line Loading @@ -45,7 +45,7 @@ RSpec.shared_examples "a tracing instrumenter" do expected_tags.each do |name, value| expect(fake_span).to receive(:set_tag).with(name, value) end allow(fake_span).to receive(:set_tag).with("error", true) allow(fake_span).to receive(:set_tag) allow(fake_span).to receive(:log_kv) allow(fake_scope).to receive(:close) Loading @@ -54,7 +54,14 @@ RSpec.shared_examples "a tracing instrumenter" do end it "logs an exception on the span" do # ... allow(fake_span).to receive(:set_tag) expect(fake_span).to receive(:set_tag).with("error", true) expect(fake_span).to receive(:log_kv) allow(fake_scope).to receive(:close) instrumenter.finish("event name", "id", payload.merge(exception: StandardError.new)) end end end