Sha256: 03800aa987f92fafaae89f2c201c8319b290970a08cfdfa603e8b21a47c133d2
Contents?: true
Size: 701 Bytes
Versions: 3
Compression:
Stored size: 701 Bytes
Contents
require File.expand_path('../spec_helper', __FILE__) require "pid_behavior" if ChildProcess.windows? describe ChildProcess::Windows::IO do let(:io) { ChildProcess::Windows::IO.new } it_behaves_like "a platform that provides the child's pid" it "raises an ArgumentError if given IO does not respond to :fileno" do lambda { io.stdout = nil }.should raise_error(ArgumentError, /must have :fileno or :to_io/) end it "raises an ArgumentError if the #to_io does not return an IO " do fake_io = Object.new def fake_io.to_io() StringIO.new end lambda { io.stdout = fake_io }.should raise_error(ArgumentError, /must have :fileno or :to_io/) end end end
Version data entries
3 entries across 3 versions & 2 rubygems