Sha256: 5051f59949dacbe6b301e2df771a2ec81822274b900432c0fdcb2f5e2a0ed37f

Contents?: true

Size: 573 Bytes

Versions: 15

Compression:

Stored size: 573 Bytes

Contents

require 'spec_helper'

describe Appsignal::EventFormatter::ActiveRecord::InstantiationFormatter do
  let(:klass)     { Appsignal::EventFormatter::ActiveRecord::InstantiationFormatter }
  let(:formatter) { klass.new }

  it "should register request.net_http" do
    Appsignal::EventFormatter.registered?('instantiation.active_record', klass).should be_true
  end

  describe "#format" do
    let(:payload) do
      {
        record_count: 1,
        class_name: 'User'
      }
    end

    subject { formatter.format(payload) }

    it { should == ['User', nil] }
  end
end

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
appsignal-1.0.4 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.1.0.beta.6 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.3 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.3.beta.2 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.3.beta.1 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.1.0.beta.5 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.1.0.beta.4 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.1.0.beta.3 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.1.0.beta.2 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.1.0.beta.1 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.2 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.2.beta.4 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.2.beta.3 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.2.beta.2 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb
appsignal-1.0.2.beta.1 spec/lib/appsignal/event_formatter/active_record/instantiation_formatter_spec.rb