Sha256: bc30ce40977491d64e6b69811194867764ad16a7bf3d038bf0f3fa31c20f49d9

Contents?: true

Size: 596 Bytes

Versions: 48

Compression:

Stored size: 596 Bytes

Contents

require 'spec_helper'

describe "Sequel integration", if: sequel_present? do
  let(:db) { Sequel.sqlite }

  before do
    start_agent
  end

  context "with Sequel" do
    before { Appsignal::Transaction.create('uuid', Appsignal::Transaction::HTTP_REQUEST, 'test') }

    it "should instrument queries" do
      expect( Appsignal::Extension ).to receive(:start_event)
        .at_least(:once)
      expect( Appsignal::Extension ).to receive(:finish_event)
        .at_least(:once)
        .with(kind_of(Integer), "sql.sequel", "", kind_of(String), 1)

      db['SELECT 1'].all
    end
  end
end

Version data entries

48 entries across 48 versions & 1 rubygems

Version Path
appsignal-1.2.0.beta.1 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.2.0.alpha.6 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.2.0.alpha.5 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.2.0.alpha.4 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.9 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.9.beta.2 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.9.beta.1 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.8 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.2.0.alpha.3 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.7 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.2.0.alpha.2 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.7.beta.2 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.2.0.alpha.1 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.7.beta.1 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.6 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.6.beta.1 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.5 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.5.beta.4 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.5.beta.3 spec/lib/appsignal/hooks/sequel_spec.rb
appsignal-1.1.5.beta.2 spec/lib/appsignal/hooks/sequel_spec.rb