Refactored upload functions into Bucket.
Add test_upload_file
Fix erroneous coverage reporting.
More tests.