Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
getHomeDirectoryPath fails when ENV is stubbed (RSpec) #2167
How to reproduce:
class Foo; def self.(name); ENV[name]; end; end Object.__send__(:remove_const, 'ENV') Object.const_set('ENV', Foo) File.expand_path('~/anything') # works as expected on MRI
Same on master (obviously - code hasn't changed).
I'm not an expert on Java or JRuby, so it would probably take ages for me to create a proper PR.