Fixed a unit test bug regarding uploading files