Make the new datastore testing proxy actually store the requests

This will improve error messages and allow for easier debugging
-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=123893831
This commit is contained in:
cgoldfeder 2016-06-02 12:14:56 -07:00 committed by Ben McIlwain
parent aa10792f73
commit 89066a7215
3 changed files with 36 additions and 30 deletions

View file

@ -109,7 +109,7 @@ public class ObjectifyService {
// examine the number of requests sent to datastore.
AsyncDatastoreService service = super.createRawAsyncDatastoreService(cfg);
return RegistryEnvironment.get().equals(RegistryEnvironment.UNITTEST)
? new RequestCountingAsyncDatastoreService(service)
? new RequestCapturingAsyncDatastoreService(service)
: service;
}});