Sha256: a3af43a8f3883cb04090588737aba7ffe8cb1daf936a41c5a44bebed33d649c4

Contents?: true

Size: 785 Bytes

Versions: 7

Compression:

Stored size: 785 Bytes

Contents

require 'spec_helper'

describe Scouter::Pocket do
  describe '#get_count' do
    let!(:yahoo) { 'http://www.yahoo.co.jp/' }
    let!(:google) { 'http://www.google.com/' }

    context 'when url parameter is String' do
      it 'yahoo has over 22000 like' do
        results, errors = Scouter::Pocket.get_count(yahoo)
        expect(errors).to be_empty
        expect(results[yahoo].pocket).to be >= 22000
      end
    end

    context 'when url parameter is Array' do
      it 'yahoo has over 22000 count and google has over 160000 count' do
        results, errors = Scouter::Pocket.get_count([google, yahoo])
        expect(errors).to be_empty
        expect(results[yahoo].pocket).to be >= 22000
        expect(results[google].pocket).to be >= 160000
      end
    end
  end

end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
scouter-0.0.7 spec/scouter/pocket_spec.rb
scouter-0.0.6 spec/scouter/pocket_spec.rb
scouter-0.0.5 spec/scouter/pocket_spec.rb
scouter-0.0.4 spec/scouter/pocket_spec.rb
scouter-0.0.3 spec/scouter/pocket_spec.rb
scouter-0.0.2 spec/scouter/pocket_spec.rb
scouter-0.0.1 spec/scouter/pocket_spec.rb