Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(672)

Issue 185873003: Task Manager: overhaul & re-enable task manager browser tests. (Closed)

Created:
6 years, 9 months ago by ncarter (slow)
Modified:
6 years, 9 months ago
Reviewers:
Avi (use Gerrit), jam
CC:
chromium-reviews, davidben+watch_chromium.org, extensions-reviews_chromium.org, cbentzel+watch_chromium.org, tburkard+watch_chromium.org, gavinp+prer_chromium.org, dominich+watch_chromium.org, chromium-apps-reviews_chromium.org
Visibility:
Public.

Description

Task Manager: overhaul & re-enable task manager browser tests. Fix some task manager bugs that showed up while working on these tests. Those bugs, in brief: - A couple of the resource managers didn't handle double-add properly, although it is possible for this to happen in practice if the task manager was opened after a tracked resource had been created, but before it was connected (for each of these bugs there is now a test that would fail without the fix). - On Windows (which has USE_ASH=1), panel resources were being double reported; they were tracked by both the Extension and the Panel resource provider. Eliminate a .gypi exclusion that caused the the taskmanager browser tests to not even be compiled on Aura platforms. Rewrite almost all tests to use a pattern of waiting for a row with a particular title to appear in the task manager model, rather than looking at indices. Substantially, the bread and butter of these tests are now expectations of the form: ASSERT_NO_FATAL_FAILURE(WaitForTaskManagerRows(1, MatchAnyTab())); This pattern allows these tests to be more resilent around the behavior of the GPU process, and hopefully will keep them from barfing the next time we introduce a new process type. For several of the tests, I've add new variants that show the task manager only AFTER the resources are created. This is done because the initial enumeration and the listening for new members are rather distinct codepaths. BUG=348836, 331947, 31663, 163931, 166322, 66957, 84719, 84850, 93158 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=255118

Patch Set 1 #

Patch Set 2 : Self-review fixes. #

Patch Set 3 : Re-upload after 500's #

Total comments: 7

Patch Set 4 : Fixes from avi #

Patch Set 5 : Retry upload #

Unified diffs Side-by-side diffs Delta from patch set Stats (+735 lines, -396 lines) Patch
M chrome/browser/prerender/prerender_browsertest.cc View 3 chunks +90 lines, -52 lines 0 comments Download
M chrome/browser/task_manager/extension_process_resource_provider.cc View 1 2 3 2 chunks +5 lines, -10 lines 0 comments Download
M chrome/browser/task_manager/notification_resource_provider.cc View 1 chunk +4 lines, -1 line 0 comments Download
M chrome/browser/task_manager/task_manager.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/task_manager/task_manager_browsertest.cc View 1 2 3 13 chunks +472 lines, -250 lines 0 comments Download
M chrome/browser/task_manager/task_manager_browsertest_util.h View 1 chunk +16 lines, -5 lines 0 comments Download
M chrome/browser/task_manager/task_manager_browsertest_util.cc View 2 chunks +100 lines, -48 lines 0 comments Download
M chrome/browser/task_manager/task_manager_notification_browsertest.cc View 4 chunks +47 lines, -20 lines 0 comments Download
M chrome/chrome_tests.gypi View 1 chunk +0 lines, -9 lines 0 comments Download

Messages

Total messages: 22 (0 generated)
ncarter (slow)
Hi Avi, Please have a look. I recommend starting with task_manager_browsertest_util.h which explains the rest ...
6 years, 9 months ago (2014-03-03 22:01:18 UTC) #1
Avi (use Gerrit)
On 2014/03/03 22:01:18, ncarter wrote: > Hi Avi, > > Please have a look. I ...
6 years, 9 months ago (2014-03-03 22:08:09 UTC) #2
ncarter (slow)
On 2014/03/03 22:08:09, Avi wrote: > On 2014/03/03 22:01:18, ncarter wrote: > > Hi Avi, ...
6 years, 9 months ago (2014-03-03 22:10:59 UTC) #3
Avi (use Gerrit)
On 2014/03/03 22:10:59, ncarter wrote: > On 2014/03/03 22:08:09, Avi wrote: > > On 2014/03/03 ...
6 years, 9 months ago (2014-03-03 22:28:33 UTC) #4
ncarter (slow)
I could put it in a macro, but not a function. ASSERT_NO_FATAL_FAILURE does two things, ...
6 years, 9 months ago (2014-03-03 22:42:47 UTC) #5
ncarter (slow)
Oh, hmm .. I could make these ASSERT_TRUE's if I had the WaitForTaskManagerRows return a ...
6 years, 9 months ago (2014-03-03 22:44:40 UTC) #6
Avi (use Gerrit)
I like this a lot. The one main issue I have is with the naming ...
6 years, 9 months ago (2014-03-03 22:52:31 UTC) #7
Avi (use Gerrit)
On 2014/03/03 22:44:40, ncarter wrote: > Oh, hmm .. I could make these ASSERT_TRUE's if ...
6 years, 9 months ago (2014-03-03 22:58:12 UTC) #8
ncarter (slow)
https://codereview.chromium.org/185873003/diff/40001/chrome/browser/task_manager/task_manager_browsertest.cc File chrome/browser/task_manager/task_manager_browsertest.cc (right): https://codereview.chromium.org/185873003/diff/40001/chrome/browser/task_manager/task_manager_browsertest.cc#newcode258 chrome/browser/task_manager/task_manager_browsertest.cc:258: IN_PROC_BROWSER_TEST_F(TaskManagerBrowserTest, KillPanelExtension) { On 2014/03/03 22:52:31, Avi wrote: > ...
6 years, 9 months ago (2014-03-03 23:01:43 UTC) #9
Avi (use Gerrit)
On 2014/03/03 23:01:43, ncarter wrote: > But actually there's one other > small difference between ...
6 years, 9 months ago (2014-03-03 23:05:10 UTC) #10
ncarter (slow)
All done, hopefully. https://codereview.chromium.org/185873003/diff/40001/chrome/browser/task_manager/extension_process_resource_provider.cc File chrome/browser/task_manager/extension_process_resource_provider.cc (right): https://codereview.chromium.org/185873003/diff/40001/chrome/browser/task_manager/extension_process_resource_provider.cc#newcode303 chrome/browser/task_manager/extension_process_resource_provider.cc:303: // Don't add WebContents (those are ...
6 years, 9 months ago (2014-03-04 01:23:11 UTC) #11
ncarter (slow)
Adding cbentzel@ and yoshiki@ as OWNERS cbentzel@chromium.org: Please review changes in chrome/browser/prerender/prerender_browsertest.cc yoshiki@chromium.org: Please review ...
6 years, 9 months ago (2014-03-04 01:30:08 UTC) #12
Avi (use Gerrit)
FWIW this LGTM
6 years, 9 months ago (2014-03-04 02:24:33 UTC) #13
ncarter (slow)
-yoshiki, -cbentzel: asking jam@ for OWNERS approval instead. +jam : approval required.
6 years, 9 months ago (2014-03-05 00:05:05 UTC) #14
jam
rubberstamp lgtm
6 years, 9 months ago (2014-03-05 08:52:22 UTC) #15
ncarter (slow)
The CQ bit was checked by nick@chromium.org
6 years, 9 months ago (2014-03-05 16:14:05 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/nick@chromium.org/185873003/70001
6 years, 9 months ago (2014-03-05 16:14:10 UTC) #17
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-05 17:26:17 UTC) #18
commit-bot: I haz the power
Retried try job too often on win_rel for step(s) base_unittests, browser_tests, interactive_ui_tests, net_unittests, unit_tests http://build.chromium.org/p/tryserver.chromium/buildstatus?builder=win_rel&number=275364
6 years, 9 months ago (2014-03-05 17:26:18 UTC) #19
ncarter (slow)
The CQ bit was checked by nick@chromium.org
6 years, 9 months ago (2014-03-05 17:33:29 UTC) #20
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/nick@chromium.org/185873003/70001
6 years, 9 months ago (2014-03-05 17:34:48 UTC) #21
commit-bot: I haz the power
6 years, 9 months ago (2014-03-05 19:44:47 UTC) #22
Message was sent while issue was closed.
Change committed as 255118

Powered by Google App Engine
This is Rietveld 408576698