Sha256: b600748d8ab19fe78cb29c068ac5384583ddeb68055dab909572bff257d94338

Contents?: true

Size: 435 Bytes

Versions: 29

Compression:

Stored size: 435 Bytes

Contents

require 'spec_helper'
require 'roqua/support/stats'

describe 'Stats' do
  let(:backend) { double("StatsBackend") }
  let(:stats)   { Roqua::Support::Stats.new(backend) }

  before do
    Roqua.appname = 'appname'
  end

  describe 'tracking a value' do
    it 'reports to backend' do
      expect(backend).to receive(:submit).with('appname.data_export.duration', 2.3)
      stats.submit('data_export.duration', 2.3)
    end
  end
end

Version data entries

29 entries across 29 versions & 1 rubygems

Version Path
roqua-support-0.4.4 spec/roqua/support/stats_spec.rb
roqua-support-0.4.3 spec/roqua/support/stats_spec.rb
roqua-support-0.4.2 spec/roqua/support/stats_spec.rb
roqua-support-0.4.1 spec/roqua/support/stats_spec.rb
roqua-support-0.4.0 spec/roqua/support/stats_spec.rb
roqua-support-0.3.5 spec/roqua/support/stats_spec.rb
roqua-support-0.3.4 spec/roqua/support/stats_spec.rb
roqua-support-0.3.3 spec/roqua/support/stats_spec.rb
roqua-support-0.3.2 spec/roqua/support/stats_spec.rb
roqua-support-0.3.1 spec/roqua/support/stats_spec.rb
roqua-support-0.3.0 spec/roqua/support/stats_spec.rb
roqua-support-0.1.34 spec/roqua/support/stats_spec.rb
roqua-support-0.1.33 spec/roqua/support/stats_spec.rb
roqua-support-0.1.32 spec/roqua/support/stats_spec.rb
roqua-support-0.1.31 spec/roqua/support/stats_spec.rb
roqua-support-0.1.30 spec/roqua/support/stats_spec.rb
roqua-support-0.1.29 spec/roqua/support/stats_spec.rb
roqua-support-0.1.28 spec/roqua/support/stats_spec.rb
roqua-support-0.1.27 spec/roqua/support/stats_spec.rb
roqua-support-0.1.26 spec/roqua/support/stats_spec.rb