Fix FakeFS::File.size? #161

Closed
wants to merge 4 commits into
from

Projects

None yet

2 participants

@tovodeverett
Contributor

The documentation for FileTest::size? in both Ruby 1.8.7 and 1.9.3 indicates that it should return the size of the file (not true) if the file is not zero-length. I modified the test suite and the implementation for FakeFS::File.size? to match the documented behavior.

Again, only merge the most recent commit.

tovodeverett added some commits Nov 26, 2012
@tovodeverett tovodeverett Updating Gemfile so I can run tests. 3ea9f69
@tovodeverett tovodeverett Merge remote-tracking branch 'upstream/master' so I can work on more
features!
077f9e6
@tovodeverett tovodeverett Ran bundle update. 831a613
@tovodeverett tovodeverett Fixed both File.size? and the test for such to match the documented
behavior for both Ruby 1.8.7 and 1.9.3, which is to return nil if
the file is missing or is a zer-length file, but is to otherwise
return the actual size (not true as fakefs used to return).
b2feab3
Collaborator

Merged in e1388f7. Thanks!

@tovodeverett tovodeverett deleted the tovodeverett:fix_sizequestion branch Feb 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment