Sha256: c40269d7c9496004ebed066801d26684dbdac577fc37b9be10e5dc7f7c3be1ab

Contents?: true

Size: 604 Bytes

Versions: 7

Compression:

Stored size: 604 Bytes

Contents

require 'test_helper'

class InstrumentActionTest < ActiveSupport::IntegrationCase

  test 'instrument controller action' do
    visit instrument_action_path

    # puts aggregate.instance_variable_get(:@cache).queued.inspect
    # puts counters.instance_variable_get(:@cache).inspect

    source = 'InstrumentActionController.inst.html'

    base = 'rails.action.request'
    timings = %w{time time.db time.view}
    timings.each do |t|
      assert_equal 1, aggregate.fetch("#{base}.#{t}", source: source)[:count]
    end

    assert_equal 1, counters.fetch("#{base}.total", source: source)
  end

end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
librato-rails-1.3.0 test/integration/instrument_action_test.rb
librato-rails-1.2.0 test/integration/instrument_action_test.rb
librato-rails-1.1.0 test/integration/instrument_action_test.rb
librato-rails-1.0.0 test/integration/instrument_action_test.rb
librato-rails-0.12.0 test/integration/instrument_action_test.rb
librato-rails-0.12.0.beta test/integration/instrument_action_test.rb
librato-rails-0.11.1 test/integration/instrument_action_test.rb