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

Issue 16482: Refactor the render widget unittest so it can be reused to create a render vi... (Closed)

Created:
11 years, 12 months ago by brettw
Modified:
9 years, 7 months ago
CC:
chromium-reviews_googlegroups.com
Visibility:
Public.

Description

Refactor the render widget unittest so it can be reused to create a render view unit test. Change the mock render thread to save all IPC messages it is asked to send so that tests can verify that the correct ones were sent. There are some new functions that support this checking. Plumb the form state change notification through the render view so that we will correctly update the form state to the browser. Write two RenderView unit tests. One arbitrarily tests OnLoadAlternateHTMLText which I used as a testcase for my testing framework. The other tests the above form state change notification. I had to expose the timeout of this message through the RenderView API so that the test can change it. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=7549

Patch Set 1 #

Patch Set 2 : '' #

Total comments: 1

Patch Set 3 : '' #

Total comments: 5

Patch Set 4 : '' #

Patch Set 5 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+561 lines, -226 lines) Patch
M chrome/common/common.vcproj View 1 3 1 chunk +16 lines, -0 lines 0 comments Download
M chrome/common/ipc_message_utils.h View 3 4 1 chunk +3 lines, -1 line 0 comments Download
A chrome/renderer/mock_render_process.h View 1 2 1 chunk +25 lines, -0 lines 0 comments Download
A chrome/renderer/mock_render_thread.h View 1 2 3 1 chunk +116 lines, -0 lines 0 comments Download
A chrome/renderer/mock_render_thread.cc View 1 2 3 1 chunk +135 lines, -0 lines 0 comments Download
M chrome/renderer/render_thread.h View 3 3 chunks +9 lines, -5 lines 0 comments Download
M chrome/renderer/render_thread.cc View 3 2 chunks +3 lines, -3 lines 0 comments Download
M chrome/renderer/render_view.h View 1 3 6 chunks +21 lines, -5 lines 0 comments Download
M chrome/renderer/render_view.cc View 1 2 3 13 chunks +46 lines, -40 lines 0 comments Download
A chrome/renderer/render_view_unittest.cc View 1 chunk +128 lines, -0 lines 0 comments Download
M chrome/renderer/render_widget_unittest.cc View 1 2 3 1 chunk +33 lines, -138 lines 0 comments Download
M chrome/test/unit/unittests.vcproj View 1 2 3 4 chunks +19 lines, -21 lines 0 comments Download
M webkit/glue/chrome_client_impl.h View 3 1 chunk +1 line, -2 lines 0 comments Download
M webkit/glue/chrome_client_impl.cc View 3 1 chunk +6 lines, -0 lines 0 comments Download
M webkit/glue/chromium_bridge_impl.cc View 3 1 chunk +0 lines, -6 lines 0 comments Download
M webkit/glue/webkit_glue.h View 3 1 chunk +0 lines, -5 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
brettw
11 years, 12 months ago (2008-12-29 18:52:55 UTC) #1
rvargas (doing something else)
There are a few lint errors. If using_npapi is not intentional, looks good after removing ...
11 years, 12 months ago (2008-12-29 19:22:56 UTC) #2
brettw
I was doing the rest of my form state changes as a separate patch, but ...
11 years, 11 months ago (2008-12-31 00:23:50 UTC) #3
rvargas (doing something else)
Nice overall. Just a few comments. http://codereview.chromium.org/16482/diff/19/604 File chrome/renderer/mock_render_thread.h (right): http://codereview.chromium.org/16482/diff/19/604#newcode10 Line 10: #include "base/linked_ptr.h" ...
11 years, 11 months ago (2008-12-31 02:09:29 UTC) #4
brettw
I fixed everything. http://codereview.chromium.org/16482/diff/19/604 File chrome/renderer/mock_render_thread.h (right): http://codereview.chromium.org/16482/diff/19/604#newcode22 Line 22: typedef std::pair<IPC::Message, char*> MessagePair; I ...
11 years, 11 months ago (2009-01-01 23:01:39 UTC) #5
rvargas (doing something else)
11 years, 11 months ago (2009-01-05 18:03:16 UTC) #6
LGTM

Powered by Google App Engine
This is Rietveld 408576698