Add file tests, clean up and simplify

Squashed commit of the following:

commit 14710083caa38a3830271950233b8c86d12a48e1
Author: Damian Jansen <djansen@redhat.com>
Date:   Mon Nov 10 12:35:03 2014 +1000

    Move apikey to constant, and html file data to static var

commit 37edef8882204c2d6b6061fc95c5053ba299cae7
Author: Damian Jansen <djansen@redhat.com>
Date:   Thu Sep 4 15:39:20 2014 +1000

    Add file tests, clean up and simplify

    - Test html, idml, dtd, odg/p/s/t File type upload
    - Use ZanataRestCaller rather than manually creating projects, versions
    - Remove unused imports
    - Add a null pointer check on opening files