You should also test for un-touchable files: Non-existing file in a non-writable directly.