Fix long unit tests in DownloadProtectionServiceTest
We had a few tests that wanted to inspect the ClientDownloadRequest, but didn't do anything with the TestURLLoaderFactory. This led to the test waiting for 7 seconds, until the timeout kicks in. This CL adds calls to PrepareResponse, to mock out the network response, so that we no longer wait for a timeout. All unit tests under DownloadProtectionServiceTest now take <1s, with the worst around 200ms. Bug: 896796 Change-Id: I1c8f24c962fbb5d13e2a86ecfda6f80c1d19d1f4 Reviewed-on: https://chromium-review.googlesource.com/c/1299502Reviewed-by:Nathan Parker <nparker@chromium.org> Commit-Queue: Daniel Rubery <drubery@chromium.org> Cr-Commit-Position: refs/heads/master@{#603511}
Showing
Please register or sign in to comment