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

Unified Diff: content/test/data/media/peerconnection-call.html

Issue 240403003: Adding lenient mode to WebRTC audio tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Passing parameter to test instead of global. Created 6 years, 8 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 | « content/browser/media/webrtc_browsertest.cc ('k') | content/test/data/media/webrtc_test_audio.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/test/data/media/peerconnection-call.html
diff --git a/content/test/data/media/peerconnection-call.html b/content/test/data/media/peerconnection-call.html
index 017d974e2ec6cc27b351afc5dd9e5b154553a024..1c7b5bf8ac61afa04d08635d3ce92469553af6b2 100644
--- a/content/test/data/media/peerconnection-call.html
+++ b/content/test/data/media/peerconnection-call.html
@@ -300,7 +300,7 @@
remoteAudioTrack.enabled = enabled;
}
- function callAndEnsureAudioIsPlaying() {
+ function callAndEnsureAudioIsPlaying(beLenient) {
createConnections(null);
navigator.webkitGetUserMedia({audio: true, video: true},
addStreamToBothConnectionsAndNegotiate, printGetUserMediaError);
@@ -310,7 +310,7 @@
var onCallEstablished = function() {
// Gather 50 samples per second for 2 seconds.
gatherAudioLevelSamples(gSecondConnection, 100, 50, function(samples) {
- verifyAudioIsPlaying(samples);
+ verifyAudioIsPlaying(samples, beLenient);
eventOccured();
});
@@ -321,8 +321,8 @@
detectVideoPlaying('remote-view-2', onCallEstablished);
}
- function callAndEnsureAudioTrackMutingWorks() {
- callAndEnsureAudioIsPlaying();
+ function callAndEnsureAudioTrackMutingWorks(beLenient) {
+ callAndEnsureAudioIsPlaying(beLenient);
setAllEventsOccuredHandler(function() {
// Call is up, now mute the track and check everything goes silent (give
// it a small delay though, we don't expect it to happen instantly).
@@ -337,8 +337,8 @@
});
}
- function callAndEnsureAudioTrackUnmutingWorks() {
- callAndEnsureAudioIsPlaying();
+ function callAndEnsureAudioTrackUnmutingWorks(beLenient) {
+ callAndEnsureAudioIsPlaying(beLenient);
setAllEventsOccuredHandler(function() {
// Mute, wait a while, unmute, verify audio gets back up.
enableRemoteAudio(gSecondConnection, false);
@@ -351,7 +351,7 @@
// Sample for four seconds here; it can take a bit of time for audio to
// get back up after the unmute.
gatherAudioLevelSamples(gSecondConnection, 200, 50, function(samples) {
- verifyAudioIsPlaying(samples);
+ verifyAudioIsPlaying(samples, beLenient);
reportTestSuccess();
});
}, 1500);
« no previous file with comments | « content/browser/media/webrtc_browsertest.cc ('k') | content/test/data/media/webrtc_test_audio.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698