Add SetTestingFactoryAndUse variant for KeyedService subclasses
SetTestingFactoryAndUse often requires users to do two casts themselves: an upcast of their service to KeyedService in their TestingFactory implementation, then a downcast from KeyedService to their service subclass on the result. This adds a method, SetTestingSubclassFactoryAndUse, which does these casts internally. Change-Id: I6d77d06dd06ebcb212498e2692f2ec9f1fb584b0 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2244095 Commit-Queue: Collin Baker <collinbaker@chromium.org> Reviewed-by:Henrique Nakashima <hnakashima@chromium.org> Cr-Commit-Position: refs/heads/master@{#779614}
Showing
Please register or sign in to comment