Added workaround to the current API revision chaos.


BUG=


Review URL: https://chromiumcodereview.appspot.com/10958074

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@158780 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/test/data/webrtc/jsep01_call.js b/chrome/test/data/webrtc/jsep01_call.js
index 647179a..7a934ca 100644
--- a/chrome/test/data/webrtc/jsep01_call.js
+++ b/chrome/test/data/webrtc/jsep01_call.js
@@ -37,7 +37,16 @@
   try {
     peerConnection = new webkitRTCPeerConnection(servers, null);
   } catch (exception) {
-    failTest('Failed to create peer connection: ' + exception);
+    // TODO(phoglund): Remove once the URI-requiring revisions are gone.
+    debug('Failed to create connection: maybe we need to fall ' +
+          'back to the old API?');
+    servers = {iceServers:[{uri:"stun:" + stun_server}]};
+    try {
+      peerConnection = new webkitRTCPeerConnection(servers, null);
+      debug('Yeah, we could use the old API.');
+    } catch (exception) {
+      failTest('Failed to create peer connection: ' + exception);
+    }
   }
   peerConnection.onaddstream = addStreamCallback_;
   peerConnection.onremovestream = removeStreamCallback_;