Properly test repository file uploads

Properly test whether it is possible to issue an HTTP POST request to
`api/v2/repositories/:id/upload_content`. Make the test for this feature submit
file data to the server in a correct manner.
Merge pull request #1318 from Ichimonji10/test-repository

Properly test repository file uploads