Sha256: 1bb9c5b805d0ac6643810486e60d861cda92b12335c164986fb68128c4de3665

Contents?: true

Size: 744 Bytes

Versions: 42

Compression:

Stored size: 744 Bytes

Contents

require 'spec_helper'

describe FbGraph::ReachEstimate, '.new' do
  it 'should setup all supported attributes' do
    attributes = {
      :users => 5503300,
      :bid_estimations => [
        {
          :location => 3,
          :cpc_min => 27,
          :cpc_median => 37,
          :cpc_max => 48,
          :cpm_min => 8,
          :cpm_median => 11,
          :cpm_max => 14
        }
      ],
      :imp_estimates => []
    }
    estimate = FbGraph::ReachEstimate.new(attributes)
    estimate.users.should == 5503300
    estimate.cpc_min.should == 27
    estimate.cpc_median.should == 37
    estimate.cpc_max.should == 48
    estimate.cpm_min.should == 8
    estimate.cpm_median.should == 11
    estimate.cpm_max.should == 14
  end
end

Version data entries

42 entries across 42 versions & 1 rubygems

Version Path
fb_graph-2.5.1 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.5.0 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.20 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.19 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.18 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.17 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.16 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.15 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.14 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.13 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.12 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.11 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.10 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.9 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.8 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.7 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.6 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.4 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.3 spec/fb_graph/reach_estimate_spec.rb
fb_graph-2.4.2 spec/fb_graph/reach_estimate_spec.rb