Sha256: 510503fb917fcce447f3c5d4aea29b788f12bfdeef33f4f017e61ef1d0fe821e

Contents?: true

Size: 633 Bytes

Versions: 68

Compression:

Stored size: 633 Bytes

Contents

require 'spec_helper'

begin
  require 'sinatra'
rescue LoadError
end

if defined?(::Sinatra)
  ENV['APPSIGNAL_PUSH_API_KEY'] = 'key'
  require 'appsignal/integrations/sinatra'

  describe "Sinatra integration" do
    context "logger" do
      subject { Appsignal.logger }

      it { should be_a Logger }
    end

    context "config" do
      subject { Appsignal.config }

      it { should be_a(Appsignal::Config) }
    end

    it "should have added the instrumentation middleware" do
      Sinatra::Application.middleware.to_a.should include(
        [Appsignal::Rack::SinatraInstrumentation, [], nil]
      )
    end
  end
end

Version data entries

68 entries across 68 versions & 1 rubygems

Version Path
appsignal-0.12.beta.39 spec/lib/appsignal/integrations/sinatra_spec.rb
appsignal-0.12.beta.38 spec/lib/appsignal/integrations/sinatra_spec.rb
appsignal-0.12.beta.37 spec/lib/appsignal/integrations/sinatra_spec.rb
appsignal-0.12.beta.36 spec/lib/appsignal/integrations/sinatra_spec.rb
appsignal-0.12.beta.35 spec/lib/appsignal/integrations/sinatra_spec.rb
appsignal-0.12.beta.34 spec/lib/appsignal/integrations/sinatra_spec.rb
appsignal-0.12.beta.33 spec/lib/appsignal/integrations/sinatra_spec.rb
appsignal-0.12.beta.32 spec/lib/appsignal/integrations/sinatra_spec.rb