Sha256: 72991887926c7e0d4f0e45edc1d009f6a9b86aee3e625841fdbe2b1cbaa59dbe

Contents?: true

Size: 552 Bytes

Versions: 96

Compression:

Stored size: 552 Bytes

Contents

# frozen_string_literal: true

describe Appsignal::EventFormatter::Rom::SqlFormatter do
  let(:klass) { described_class }
  let(:formatter) { klass.new }

  it "registers the sql event formatter" do
    expect(Appsignal::EventFormatter.registered?("sql.dry", klass)).to be_truthy
  end

  describe "#format" do
    let(:payload) do
      {
        :name => "postgres",
        :query => "SELECT * FROM users"
      }
    end
    subject { formatter.format(payload) }

    it { is_expected.to eq ["query.postgres", "SELECT * FROM users", 1] }
  end
end

Version data entries

96 entries across 96 versions & 1 rubygems

Version Path
appsignal-4.0.6-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.6 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.5-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.5 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.4-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.4 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.3-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.3 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.2-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.2 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.1-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.1 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.0-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.0 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-3.13.1-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-3.13.1 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-3.13.1.alpha.1-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-3.13.1.alpha.1 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.0.beta.2-java spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb
appsignal-4.0.0.beta.2 spec/lib/appsignal/event_formatter/rom/sql_formatter_spec.rb