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

Issue 12258042: Rewrite WebContentsVideoCaptureDeviceTest. (Closed)

Created:
7 years, 10 months ago by ncarter (slow)
Modified:
7 years, 9 months ago
Reviewers:
miu
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam, feature-media-reviews_chromium.org
Visibility:
Public.

Description

Rewrite WebContentsVideoCaptureDeviceTest. The motivation here was to support CopyFromCompositingSurfaceToVideoFrame. What's new: we use or extend TestWebContents, TestRenderViewHost, and TestRenderWidgetHostView instead of directly overriding the impls. As a result we can use the WebContentsVideoCaptureDevice's regular constructor, and eliminate all the ForTesting setup code. The main test thread doubles as the UI thread. Instead of an event signaling a condition variable, we run the message loop until the event causes posts a Quit task. BUG=175565, 158641, 159234 TEST=content_unittests,browser_tests TBR=wjia@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=185181

Patch Set 1 #

Patch Set 2 : Fix a comment. #

Patch Set 3 : Restore test timeout behavior. #

Patch Set 4 : Style fixes. #

Total comments: 24

Patch Set 5 : Fix shutdown issues by restoring destroy_cb. #

Patch Set 6 : Yuri's fixes. #

Patch Set 7 : Remove linux test suppression. #

Patch Set 8 : Header fix. #

Patch Set 9 : Fix leaks, add a tale-of-woe comment. #

Patch Set 10 : Fix another leak. #

Patch Set 11 : Check is_null before invoking callback. #

Patch Set 12 : Refiddle test exclusions. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+406 lines, -241 lines) Patch
M content/browser/renderer_host/media/video_capture_manager.cc View 1 2 3 4 1 chunk +1 line, -1 line 0 comments Download
M content/browser/renderer_host/media/web_contents_capture_util.h View 1 chunk +3 lines, -1 line 0 comments Download
M content/browser/renderer_host/media/web_contents_video_capture_device.h View 1 2 3 4 5 2 chunks +12 lines, -14 lines 0 comments Download
M content/browser/renderer_host/media/web_contents_video_capture_device.cc View 1 2 3 4 5 6 7 8 9 10 12 chunks +41 lines, -73 lines 0 comments Download
M content/browser/renderer_host/media/web_contents_video_capture_device_unittest.cc View 1 2 3 4 5 6 7 8 9 8 chunks +346 lines, -149 lines 0 comments Download
M tools/valgrind/gtest_exclude/content_unittests.gtest.txt View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -3 lines 0 comments Download
A tools/valgrind/gtest_exclude/content_unittests.gtest-tsan.txt View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +2 lines, -0 lines 0 comments Download

Messages

Total messages: 8 (0 generated)
ncarter (slow)
Yuri, please review. One thing I'm not clear on, is how to get the destruction ...
7 years, 10 months ago (2013-02-15 00:38:14 UTC) #1
miu
You asked about how the test should handle the asynchronous DeAllocate(). The problem is how ...
7 years, 10 months ago (2013-02-20 06:45:10 UTC) #2
ncarter (slow)
PTAL. https://codereview.chromium.org/12258042/diff/15001/content/browser/renderer_host/media/web_contents_capture_util.h File content/browser/renderer_host/media/web_contents_capture_util.h (right): https://codereview.chromium.org/12258042/diff/15001/content/browser/renderer_host/media/web_contents_capture_util.h#newcode14 content/browser/renderer_host/media/web_contents_capture_util.h:14: class CONTENT_EXPORT WebContentsCaptureUtil { On 2013/02/20 06:45:10, Yuri ...
7 years, 10 months ago (2013-02-22 02:16:11 UTC) #3
miu
lgtm Nice work.
7 years, 10 months ago (2013-02-26 20:22:30 UTC) #4
miu
lgtm through patchset 12.
7 years, 9 months ago (2013-02-28 05:32:33 UTC) #5
ncarter (slow)
TBRing wjia because of one line in video_capture_controller
7 years, 9 months ago (2013-02-28 06:26:06 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/nick@chromium.org/12258042/48005
7 years, 9 months ago (2013-02-28 06:26:35 UTC) #7
commit-bot: I haz the power
7 years, 9 months ago (2013-02-28 08:44:48 UTC) #8
Message was sent while issue was closed.
Change committed as 185181

Powered by Google App Engine
This is Rietveld 408576698