Sha256: 3a8b85d48cf9d55ef74d1ac75614fc6d1c14944505e803580af7ca7fddeb3349

Contents?: true

Size: 788 Bytes

Versions: 1

Compression:

Stored size: 788 Bytes

Contents

require 'spec/helper/all'

DELAY = 0.25

__END__
describe EMJack do

  it "should fire sequential Beanstalk requests" do
    pending
    
    EventMachine.run do
      Fiber.new {
        jack = EMJack::Connection.new

        r = jack.use('mytube')
        r.should == 'mytube'

        EventMachine.stop
      }.resume
    end
  end

  it "should fire multiple requests in parallel" do
    pending
    
    EventMachine.run do
      Fiber.new {
        jack = EMJack::Connection.new

        multi = EventMachine::Multi.new
        multi.add jack.ause('mytube-1')
        multi.add jack.ause('mytube-2')
        res = multi.perform
        
        res.responses.size.should == 2
        p [:multi, res.responses]
        
        EventMachine.stop
      }.resume

    end
  end
  
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
em-synchrony-0.1.4 spec/beanstalk_spec.rb