rubinius/rubinius — pull request #2555 by YorickPeterse (2013-08-15 20:54:04+00:00)
Title: Better way of checking for group permissions.

Commit message explains the reasoning itself. Before we merge this in I'd like to have some feedback on the way I'm currently testing this as well as how to test this properly for the `_real?` family of methods as well as `writable?`, etc.

One problem I foresee with this testing setup is that the tests will break if the user has only 1 group as `(Process.groups - [Process.egid]).sample.to_i` would return `0`, though I'm not entirely sure how `File.chown` behaves in that case.