rubyspec/mspec — pull request #19 by jc00ke (2012-01-09 08:03:59+00:00)
Title: Adding env key to ruby_exe options hash

I'll gladly take pointers on the spec with all those `.should_receive` lines. I did test this manually with `tmp/env_var_spec.rb` with contents:

```ruby
require File.expand_path('../../lib/mspec', __FILE__)

describe "The -Xversion command line option" do

it "sets env vars correctly" do
opts = { :args => %Q{-e "puts ENV['foo']" 2>&1}, :env => { "foo" => "bar" } }
ruby_exe(nil, opts).chomp.should == "bar"
end
end
```

and it passed ok.