Sha256: b947cd99938a434b8285780b3278b92c021b307a9962d147e47ebc5e4096f02d

Contents?: true

Size: 487 Bytes

Versions: 4

Compression:

Stored size: 487 Bytes

Contents

require 'spec_helper'

describe FluQ::Buffer::Base do

  its(:config)  { should == {max_size: 268435456} }
  its(:size)    { should be(0) }
  its(:name)    { should == "base" }
  it { should respond_to(:write) }
  it { should respond_to(:close) }
  it { should_not be_full }

  it 'should drain' do
    subject.drain {|io| io.should be_instance_of(StringIO) }
  end

  describe 'when size exeeds limit' do
    before { subject.stub size: 268435457 }
    it { should be_full }
  end

end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
fluq-0.7.5 spec/fluq/buffer/base_spec.rb
fluq-0.7.3 spec/fluq/buffer/base_spec.rb
fluq-0.7.1 spec/fluq/buffer/base_spec.rb
fluq-0.7.0 spec/fluq/buffer/base_spec.rb