Sha256: f28ad87edd8955ead366909f9f84776e6d4479cc55d1e5ff572a15356e465663
Contents?: true
Size: 617 Bytes
Versions: 6
Compression:
Stored size: 617 Bytes
Contents
require 'spec_helper' describe UV::Idle do let(:handle_name) { :idle } let(:loop) { double() } let(:pointer) { double() } subject { UV::Idle.new(loop, pointer) } it_behaves_like 'a handle' describe "#start" do it "requires a block" do expect { subject.start }.to raise_error(ArgumentError) end it "calls UV.idle_start" do UV.should_receive(:idle_start).with(pointer, subject.method(:on_idle)) subject.start { |e| } end end describe "#stop" do it "calls UV.idle_stop" do UV.should_receive(:idle_stop).with(pointer) subject.stop end end end
Version data entries
6 entries across 6 versions & 1 rubygems