Sha256: 10dc509554f0126e9df395855b1d093ccda46aa025d10a931c392b7aee17afa5

Contents?: true

Size: 601 Bytes

Versions: 4

Compression:

Stored size: 601 Bytes

Contents

require 'spec_helper'

describe 'RSpec' do
  before do
    @beanstalk = Beanstalk::MockPool.new ['localhost:11300']
  end

  it 'should match empty tube size' do
    @beanstalk.should have_tube_size_of(0)
  end

  it 'should match queue size' do
    @beanstalk.use 'oath'
    @beanstalk.yput :foo => 'bar'
    @beanstalk.should have_tube_size_of(1).for('oath')
  end

  it 'should match gt queue size' do
    @beanstalk.use 'oath'
    @beanstalk.yput :foo => 'bar'
    @beanstalk.yput :foo => 'bar'
    @beanstalk.yput :foo => 'bar'
    @beanstalk.should have_tube_size_of_gt(2).for('oath')
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
beanstalk-client-rspec-0.0.9 spec/rspec_spec.rb
beanstalk-client-rspec-0.0.8 spec/rspec_spec.rb
beanstalk-client-rspec-0.0.7 spec/rspec_spec.rb
beanstalk-client-rspec-0.0.6 spec/rspec_spec.rb