Sha256: b93669400b30bbf31845e96d2f1c5705d405e6dea3e372cd8e644539a74f5025
Contents?: true
Size: 431 Bytes
Versions: 2
Compression:
Stored size: 431 Bytes
Contents
require "spec_helper" describe "Agent.go!" do it "should launch a 'goroutine' that is actually a thread" do expect(Agent.go!{}).to be_a(Thread) end it "should pass into the thread any arguments passed to it" do b = nil Agent.go!(1){|a| b = a }.join expect(b).to eq(1) end it "should raise an error if no block is passed" do expect{ Agent.go! }.to raise_error(Agent::Errors::BlockMissing) end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
agent-0.12.0 | spec/go_spec.rb |
agent-0.11.0 | spec/go_spec.rb |