WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
74882
implement layout tests for <video> with media stream
https://bugs.webkit.org/show_bug.cgi?id=74882
Summary
implement layout tests for <video> with media stream
wjia
Reported
2011-12-19 13:31:20 PST
Implement the needed code to facilitate integration test for <video> with src from media stream.
Attachments
Patch
(23.87 KB, patch)
2011-12-19 14:25 PST
,
wjia
no flags
Details
Formatted Diff
Diff
Patch
(16.89 KB, patch)
2011-12-19 18:45 PST
,
wjia
no flags
Details
Formatted Diff
Diff
Patch
(8.47 KB, patch)
2011-12-21 02:31 PST
,
Tommy Widenflycht
no flags
Details
Formatted Diff
Diff
Patch
(16.21 KB, patch)
2012-01-05 15:40 PST
,
wjia
no flags
Details
Formatted Diff
Diff
Patch
(16.73 KB, patch)
2012-01-10 12:10 PST
,
wjia
no flags
Details
Formatted Diff
Diff
Patch
(16.94 KB, patch)
2012-01-11 11:53 PST
,
wjia
no flags
Details
Formatted Diff
Diff
Show Obsolete
(5)
View All
Add attachment
proposed patch, testcase, etc.
wjia
Comment 1
2011-12-19 14:25:21 PST
Created
attachment 119919
[details]
Patch
WebKit Review Bot
Comment 2
2011-12-19 14:34:33 PST
Please wait for approval from
fishd@chromium.org
before submitting because this patch contains changes to the Chromium public API.
Kent Tamura
Comment 3
2011-12-19 17:23:37 PST
Comment on
attachment 119919
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=119919&action=review
> Tools/DumpRenderTree/chromium/TestMediaStreamClient.cpp:38 > +#include "media/base/message_loop_factory.h" > +#include "media/base/pipeline.h" > +#include "media/video/capture/fake_capture_video_decoder.h"
We have to avoid using Chromium code other than webkit/support/ in DRT.
> Tools/DumpRenderTree/chromium/TestMediaStreamClient.cpp:46 > +namespace { > + > +static const int kVideoCaptureWidth = 352; > +static const int kVideoCaptureHeight = 288; > +static const int kVideoCaptureFramePerSecond = 30; > + > +} // namespace
Do not use anonymous namespace and k-prefix in WebKit code.
> Tools/DumpRenderTree/chromium/TestMediaStreamClient.h:38 > +#include "webkit/media/media_stream_client.h"
We have to avoid using Chromium code other than webkit/support/ in DRT.
wjia
Comment 4
2011-12-19 18:45:14 PST
Created
attachment 119969
[details]
Patch
wjia
Comment 5
2011-12-19 18:47:34 PST
please take another look. The TestMediaStreamClient has been moved into webkit/support in chromium (
http://codereview.chromium.org/8887004/
).
Tommy Widenflycht
Comment 6
2011-12-20 07:22:06 PST
This patch must be split into two to keep the build green at all times, so please wait with the review.
WebKit Review Bot
Comment 7
2011-12-20 13:04:39 PST
Comment on
attachment 119969
[details]
Patch
Attachment 119969
[details]
did not pass chromium-ews (chromium-xvfb): Output:
http://queues.webkit.org/results/10991359
Tommy Widenflycht
Comment 8
2011-12-21 02:31:33 PST
Created
attachment 120163
[details]
Patch
wjia
Comment 9
2012-01-05 15:40:37 PST
Created
attachment 121353
[details]
Patch
wjia
Comment 10
2012-01-05 15:46:08 PST
Please take another look. patch (id=121353) moved WebUserMediaClientMock from Source/WebKit/chromium to Tools/DumpRenderTree/chromium. Now there is no need to have 2 patches (the other is in
bug 74930
). This patch only depends on chromium patch
http://codereview.chromium.org/8887004/
.
WebKit Review Bot
Comment 11
2012-01-05 20:57:08 PST
Comment on
attachment 121353
[details]
Patch
Attachment 121353
[details]
did not pass chromium-ews (chromium-xvfb): Output:
http://queues.webkit.org/results/11122209
wjia
Comment 12
2012-01-06 15:59:55 PST
The chromium patch has been landed as
http://src.chromium.org/viewvc/chrome?view=rev&revision=116749
. With chromium
r116749
, this patch should work.
Kent Tamura
Comment 13
2012-01-09 20:16:34 PST
Would you post the same patch again please? I'd like to see EWS bot results.
wjia
Comment 14
2012-01-10 12:10:17 PST
Created
attachment 121889
[details]
Patch
Kent Tamura
Comment 15
2012-01-10 16:54:16 PST
Comment on
attachment 121889
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=121889&action=review
Some style nits and a test question.
> Tools/DumpRenderTree/chromium/WebUserMediaClientMock.cpp:45 > +WebUserMediaClientMock* WebUserMediaClientMock::create() > +{ > + return new WebUserMediaClientMock();
This should be: PassOwnPtr<WebUserMediaClientMock> WebUserMediaClientMock::create() { return adoptPtr(new WebuserMediaClientMock());
> Tools/DumpRenderTree/chromium/WebUserMediaClientMock.cpp:71 > + size_t size = 1;
nit: This should be 'const size_t'.
> Tools/DumpRenderTree/chromium/WebUserMediaClientMock.h:52 > +};
We had better have private: WebUserMediaClientMock();
> LayoutTests/platform/chromium/media/video-capture-preview.html:11 > +var preview_url = ""; > +var localStream = null;
We usually use camelCase for variable names though we don't have an official JavaScript style. preview_url -> previewURL
> LayoutTests/platform/chromium/media/video-capture-preview.html:18 > +function gotStream(s)
One-letter variable name is not good.
> LayoutTests/platform/chromium/media/video-capture-preview.html:33 > + var milliseconds = 2000; > + var replayIfTimeIsReached = function () > + { > + startPreview(); > + consoleWrite("restart preview"); > + setTimeout(endTest, 2500); > + } > + > + setTimeout(replayIfTimeIsReached, milliseconds + 100);
What do these magic numbers mean? - milliseconds = 2000 - setTimeout(..., 2500) - setTimeout(..., milliseconds + 100)
wjia
Comment 16
2012-01-11 11:53:31 PST
Created
attachment 122064
[details]
Patch
wjia
Comment 17
2012-01-11 11:55:44 PST
Thanks, Kent! The magic numbers in LayoutTests/platform/chromium/media/video-capture-preview.html are play time. In the new patch, I have consolidated them to one number. Please take another look.
Kent Tamura
Comment 18
2012-01-11 15:24:03 PST
Comment on
attachment 122064
[details]
Patch LGTM
WebKit Review Bot
Comment 19
2012-01-11 16:27:12 PST
Comment on
attachment 122064
[details]
Patch Clearing flags on attachment: 122064 Committed
r104764
: <
http://trac.webkit.org/changeset/104764
>
WebKit Review Bot
Comment 20
2012-01-11 16:27:20 PST
All reviewed patches have been landed. Closing bug.
wjia
Comment 21
2012-01-12 10:24:42 PST
***
Bug 74930
has been marked as a duplicate of this bug. ***
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug