What is the best way to unit test an application using the Google Drive API (Java client)?

It seems like applications written rely heavily on the Drive class, but short of either...

  • creating a really extensive mock (which, itself, would likely need to be tested), or
  • writing an integration test dependent on the actual Drive service

...how could such an application be tested?

Using mock frameworks like Mockito are a bit tedious with the Drive API (Java client), since usage of the Drive Java client rely on making so many chained calls (e.g., from the documentation):

Drive service = getDriveService(req, resp);
service.files().get(fileId).execute();
Edit
Report