On Fri, Jan 23, 2009 at 3:40 PM, James Byrne <li...@ruby-forum.com> wrote:
> Josh Chisholm wrote: > > We are setting environment variables in our Rakefile. We have various > > tasks that set up environment variables, then call the cucumber task. > > That's working for us under windows. > > Yes that makes sense. Referring to the Pickaxe book one reads that: > > "A Ruby program may write to the ENV object, which on most systems > changes the values of the corresponding environment variables. However, > this change is local to the process that makes it and to any > subsequently spawned child processes. This inheritance of environment > variables is illustrated in the code that follows. A subprocess changes > an environment variable and this change is seen in a process that it > then starts. However, the change is not visible to the original parent. > (This just goes to prove that parents never really know what their > children are doing.)" > > This does seem to indicate that the ENV setting made in in env.rb is > visible to the cucumber process. The inference that I draw from this is > that env.rb is processed after the ENV setting for "CUCUMBER_COLORS" has > already been used by cucumber and thus has no further effect on its > behaviour. That is correct: http://github.com/aslakhellesoy/cucumber/blob/cee08ca63fd2d234aacc231d5be342bb6fba06bc/lib/cucumber/formatters/ansicolor.rb (BTW, this is the ugliest code in Cucumber) Aslak > > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > -- Aslak (::)
_______________________________________________ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users