refactored haruploader

The original implementation of haruploader used 3 module-level functions.  It was impossible to write most unit tests with that structure.  I refactored it into an `Uploader` class with methods.

I've also fixed all the tests so they pass using the new Class.

This resolves issue #46 

/cc @benpatterson @jzoldak @clytwynec