Some tests had failed on `sudo make test-all`, mainly because root can
access any files regardless of permission. This change adds `skip`
guards into such tests.
Note that almost all tests in which `skip` guards is added, already have
"windows" guard. This is because there is no support to avoid read
access by owner on Windows.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61758 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
rather than ignoring test definition to know untestability when
executing test with `-v`.
Also this simplifies check using `MiniTest::Unit::Guard#windows?`.
This change is suggested by @MSP-Greg here:
7128849c8c (commitcomment-25836745)
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60937 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
> Note that all files are always readable
> https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/chmod-wchmod
It seems that we can't make a file unreadable with `File.chmod` on
Windows.
When file can't be read, File::EACCES is raised on Windows too. So
r60900 should work anyway, but I don't know how to let it happen by
Ruby code. I tried to open file before reading it, but I couldn't
reproduce File::EACCES too.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60901 b2dd03c8-39d4-4d8f-98ff-823fe69b080e