More unit tests for file functions.