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

Unified Diff: chrome/test/data/extensions/api_test/cast_streaming/rtp_stream_error.js

Issue 2113783002: Refactoring: Merge VideoSenderConfig and AudioSenderConfig. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed mek's comment. Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/media/cast_session_delegate.cc ('k') | media/cast/cast_config.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/extensions/api_test/cast_streaming/rtp_stream_error.js
diff --git a/chrome/test/data/extensions/api_test/cast_streaming/rtp_stream_error.js b/chrome/test/data/extensions/api_test/cast_streaming/rtp_stream_error.js
index 9db19495e35a60d1e95f38e2323bbdfa755fcdd7..b67ddf6a4c85252a511a47b200e6febdcbbf2819 100644
--- a/chrome/test/data/extensions/api_test/cast_streaming/rtp_stream_error.js
+++ b/chrome/test/data/extensions/api_test/cast_streaming/rtp_stream_error.js
@@ -31,19 +31,21 @@ chrome.test.runTests([
pass(function(stream, audioId, videoId, udpId) {
var audioParams = rtpStream.getSupportedParams(audioId)[0];
var videoParams = rtpStream.getSupportedParams(videoId)[0];
- rtpStream.onError.addListener(
- pass(function(audioId, videoId, id, msg) {
- chrome.test.assertEq(videoId, id);
- rtpStream.destroy(audioId);
- rtpStream.destroy(videoId);
- udpTransport.destroy(udpId);
- console.log(msg);
- }.bind(null, audioId, videoId)));
// Specify invalid value to trigger error.
videoParams.payload.codecName = "Animated WebP";
udpTransport.setDestination(udpId,
{address: "127.0.0.1", port: 2344});
- rtpStream.start(videoId, videoParams);
+ try {
+ rtpStream.start(videoId, videoParams);
+ chrome.test.fail();
+ } catch (e) {
+ rtpStream.stop(audioId);
+ rtpStream.stop(videoId);
+ rtpStream.destroy(audioId);
+ rtpStream.destroy(videoId);
+ udpTransport.destroy(udpId);
+ chrome.test.succeed();
+ }
}.bind(null, stream)));
}));
},
« no previous file with comments | « chrome/renderer/media/cast_session_delegate.cc ('k') | media/cast/cast_config.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698