Fix breakages while performance_browser_tests was not running on Mac.
In our vain attempt to re-enable performance_browser_tests on the Mac
bots, a number of breakages seem to have happened over the months where
we were not even aware the tests weren't running.
This change fixes all of the following:
1. Adds a BUILD dependency on //chrome:chrome_app. Without this, the
test binary would be missing many runtime dependencies (e.g., the whole
"Chrome Framework" bundle).
2. Migrate MachPortsTest to use BrowserTestBase::embedded_test_server()
instead of its own server of "fake content" for its browser tests.
3. Add base::ScopedAllowIO for a test utility class that creates and
tears down its own set of threads. It's not clear why the thread
restriction is only checked on Mac (perhaps it's in the way the
browser test's main thread is set up?). Nevertheless, it's perfectly
reasonable for the main thread to block on stopping these other threads:
After the test has run, the threads are shut down before the data
analysis begins, since we want to be sure the data sets are no longer
mutating. Also, added PRESUBMIT.py exception for this use case.
BUG=697444,722367
TBR=nduca
Review-Url: https://codereview.chromium.org/2901113003
Cr-Commit-Position: refs/heads/master@{#475773}
diff --git a/PRESUBMIT.py b/PRESUBMIT.py
index 215ffbc..7f09ce51 100644
--- a/PRESUBMIT.py
+++ b/PRESUBMIT.py
@@ -212,6 +212,8 @@
r"^content[\\\/]shell[\\\/]browser[\\\/]shell_browser_main\.cc$",
r"^content[\\\/]shell[\\\/]browser[\\\/]shell_message_filter\.cc$",
r"^content[\\\/]test[\\\/]ppapi[\\\/]ppapi_test\.cc$",
+ r"^media[\\\/]cast[\\\/]test[\\\/]utility[\\\/]" +
+ r"standalone_cast_environment\.cc$",
r"^mojo[\\\/]edk[\\\/]embedder[\\\/]" +
r"simple_platform_shared_buffer_posix\.cc$",
r"^net[\\\/]disk_cache[\\\/]cache_util\.cc$",