ruby-changes:54191
From: k0kubun <ko1@a...>
Date: Sun, 16 Dec 2018 09:56:13 +0900 (JST)
Subject: [ruby-changes:54191] k0kubun:r66412 (trunk): spec/../initialize_spec.rb: skip fd-specific spec
k0kubun 2018-12-16 09:55:56 +0900 (Sun, 16 Dec 2018) New Revision: 66412 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=66412 Log: spec/../initialize_spec.rb: skip fd-specific spec https://gist.github.com/ko1/72c03695e81a54d40649f29d0c421f26 Modified files: trunk/spec/ruby/core/io/initialize_spec.rb Index: spec/ruby/core/io/initialize_spec.rb =================================================================== --- spec/ruby/core/io/initialize_spec.rb (revision 66411) +++ spec/ruby/core/io/initialize_spec.rb (revision 66412) @@ -23,16 +23,16 @@ describe "IO#initialize" do https://github.com/ruby/ruby/blob/trunk/spec/ruby/core/io/initialize_spec.rb#L23 # initialize has closed the old descriptor lambda { IO.for_fd(@fd).close }.should raise_error(Errno::EBADF) end - end - it "calls #to_int to coerce the object passed as an fd" do - obj = mock('fileno') - fd = new_fd @name, "r:utf-8" - obj.should_receive(:to_int).and_return(fd) - @io.send :initialize, obj, 'r' - @io.fileno.should == fd - # initialize has closed the old descriptor - lambda { IO.for_fd(@fd).close }.should raise_error(Errno::EBADF) + it "calls #to_int to coerce the object passed as an fd" do + obj = mock('fileno') + fd = new_fd @name, "r:utf-8" + obj.should_receive(:to_int).and_return(fd) + @io.send :initialize, obj, 'r' + @io.fileno.should == fd + # initialize has closed the old descriptor + lambda { IO.for_fd(@fd).close }.should raise_error(Errno::EBADF) + end end it "raises a TypeError when passed an IO" do -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/