JRuby-1.7.3: possible bug in Dir.exists?

we had some weird behavior in our test suite failing while using
simplecov. basically simplecov uses an at_exit that checks $! to see if
it should exit with a non-zero code. tracking down what was happening, i
found that it appears Dir.exists? returns false, as it should, but also
sets $! without throwing an exception. see this gist to see a simple
test.rb and the console output.

https://gist.github.com/akreiling/5253467

it appears to me that this is a bug in JRuby but i am not 100% sure. any
thoughts?

thanks!
-a

Yeah this sure looks like a bug to me too…Can you open up an issue
for this? If exists? was supposed to raise on ENOENT it would be
fairly limited in value.

-Tom

On Wed, Mar 27, 2013 at 10:28 AM, Andrew K. [email protected]
wrote:

thoughts?

thanks!
-a


blog: http://blog.enebo.com twitter: tom_enebo
mail: [email protected]

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs