Clarify that SCMTool.get_file
and HostingService.get_file
return bytes.
This change goes through and decorates the various get_file
calls to make sure
that we're always returning bytes. On Python 2, 'bytes' is just an alias for
'str', but this will be important for Python 3. I've added some assertions in
the tests that handle get_file
calls.
This seems to be pretty complete, with the exception that bazaar uses str
concatenation for returning the file. I've added a big XXX comment in there and
a cast to bytes, which at least makes the return types consistent in the event
that the fetched file was able to be stuffed into an str without any errors.