implement SetWatchEvent and WaitForEvent for trace-based-tests.

Up until now, tracing-based tests have been required to either run a trace for some amount of time or use existing notification mechanisms to return control to the test.

This change adds a 'watch event' feature to trace_event_impl which can be used by tests to wait for an event to occur. This mechanism could replace the use of test-only notifications which is frowned upon as well as mock classes for catching events. Trace events also have the huge advantage of working on all chrome processes as opposed to the browser-only notification service.

BUG=139939

Review URL: https://chromiumcodereview.appspot.com/10837082

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@154552 0039d316-1c4b-4281-b951-d872f2087c98
18 files changed