diff options
author | skyostil <skyostil@chromium.org> | 2015-04-27 10:59:37 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-04-27 17:59:35 +0000 |
commit | 0becb33779f8678e2703d6ff1a73ce2b45571f98 (patch) | |
tree | ca8e900931a5e71c07db40c308a7755b15de1870 /chrome/browser/lifetime/application_lifetime.h | |
parent | 6974bf71b37bddb36ca8b1feefc013b7c47c105f (diff) | |
download | chromium_src-0becb33779f8678e2703d6ff1a73ce2b45571f98.zip chromium_src-0becb33779f8678e2703d6ff1a73ce2b45571f98.tar.gz chromium_src-0becb33779f8678e2703d6ff1a73ce2b45571f98.tar.bz2 |
Ensure tests have an active task runner
This patch modifies all tests to have a more realistic threading set-up by either:
a) adding a TestBrowserThreadBundle
b) constructing any existing TestBrowserThreadBundle earlier or
c) adding a MessageLoop as appropriate.
This makes it possible to later migrate base/ from MessageLoopProxy over to
ThreadTaskRunnerHandle, which requires an active task runner on the current thread.
BUG=465354
Review URL: https://codereview.chromium.org/1086733002
Cr-Commit-Position: refs/heads/master@{#327067}
Diffstat (limited to 'chrome/browser/lifetime/application_lifetime.h')
-rw-r--r-- | chrome/browser/lifetime/application_lifetime.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/chrome/browser/lifetime/application_lifetime.h b/chrome/browser/lifetime/application_lifetime.h index 9165754..3cf1854 100644 --- a/chrome/browser/lifetime/application_lifetime.h +++ b/chrome/browser/lifetime/application_lifetime.h @@ -116,6 +116,9 @@ void HandleAppExitingForPlatform(); // last browser window is being closed. bool ShouldStartShutdown(Browser* browser); +// Disable browser shutdown for unit tests. +void DisableShutdownForTesting(bool disable_shutdown_for_testing); + } // namespace chrome #endif // CHROME_BROWSER_LIFETIME_APPLICATION_LIFETIME_H_ |