Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: jruby/jruby
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 2f324a7dfec7
Choose a base ref
...
head repository: jruby/jruby
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 44cbb9d5c104
Choose a head ref
  • 2 commits
  • 2 files changed
  • 1 contributor

Commits on Jun 15, 2015

  1. Copy the full SHA
    8243763 View commit details
  2. Also tag this spawn spec.

    headius committed Jun 15, 2015
    Copy the full SHA
    44cbb9d View commit details
Showing with 6 additions and 0 deletions.
  1. +5 −0 spec/ruby/shared/process/spawn.rb
  2. +1 −0 spec/tags/ruby/core/kernel/spawn_tags.txt
5 changes: 5 additions & 0 deletions spec/ruby/shared/process/spawn.rb
Original file line number Diff line number Diff line change
@@ -355,6 +355,11 @@
@name.should have_data("glark")
end

it "redirects STDOUT to the given file if :out => [String name, String mode]" do
Process.wait @object.spawn(ruby_cmd("print :glark"), :out => [@name, 'w'])
@name.should have_data("glark")
end

it "redirects STDERR to the given file descriptior if :err => Fixnum" do
File.open(@name, 'w') do |file|
lambda do
1 change: 1 addition & 0 deletions spec/tags/ruby/core/kernel/spawn_tags.txt
Original file line number Diff line number Diff line change
@@ -11,6 +11,7 @@ fails:Kernel#spawn joins a new process group if :pgroup => true
fails:Kernel#spawn joins a new process group if :pgroup => 0
fails:Kernel#spawn sets the umask if given the :umask option
critical(runs very long before failing):Kernel#spawn redirects STDOUT to the given file if :out => String
critical(runs very long before failing):Kernel#spawn redirects STDOUT to the given file if :out => [String name, String mode]
critical(runs very long before failing):Kernel#spawn redirects STDERR to the given file if :err => String
fails:Kernel#spawn does NOT redirect both STDERR and STDOUT at the time to the given name
fails:Kernel#spawn raises an Errno::EACCES when passed a directory