Skip to content

Instantly share code, notes, and snippets.

@ariejan
Created December 1, 2011 16:00
Show Gist options
  • Save ariejan/1417792 to your computer and use it in GitHub Desktop.
Save ariejan/1417792 to your computer and use it in GitHub Desktop.
EM::Connection specs?
module MyApp
class Con < EM::Connection
def post_init
@queue = EM::Queue.new
end
def receive_data(data)
@queue.push(data)
end
end
end
require 'spec_helper'
describe MyApp::Con do
it "should create a queue post_init" do
# ??
end
it "should post received data on the queue" do
# ??
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment