function startCheckTest(testName) {
  chrome.test.getConfig(function(config) {
    embedder.baseGuestURL = 'http://localhost:' + config.testServer.port;
    embedder.guestURL = embedder.baseGuestURL +
        '/extensions/platform_apps/web_view/media_access' +
        '/media_check_guest.html';
    chrome.test.log('Guest url is: ' + embedder.guestURL);

    var webview = embedder.setUpGuest_();
    if (!webview) {
      return;
    }

    embedder.setUpLoadStop_(webview);

    webview.addEventListener('consolemessage', function(e) {
      window.console.log(e.message);
    });

    window.addEventListener('message', function(e) {
      var data = JSON.parse(e.data);
      if (data[0] == 'got-sources') {
        embedder.maybePassTest();
      } else {
        window.console.log('Unexpected message: ' + e.message);
      }
    });
  });
}
// Entry point for test, called by WebViewTest.
Entry point for test, called by WebViewTest.
Entry point for test called by WebViewTest .
function startCheckTest(testName) {
  chrome.test.getConfig(function(config) {
    embedder.baseGuestURL = 'http://localhost:' + config.testServer.port;
    embedder.guestURL = embedder.baseGuestURL +
        '/extensions/platform_apps/web_view/media_access' +
        '/media_check_guest.html';
    chrome.test.log('Guest url is: ' + embedder.guestURL);
    var webview = embedder.setUpGuest_();
    if (!webview) {
      return;
    }
    embedder.setUpLoadStop_(webview);
    webview.addEventListener('consolemessage', function(e) {
      window.console.log(e.message);
    });
    window.addEventListener('message', function(e) {
      var data = JSON.parse(e.data);
      if (data[0] == 'got-sources') {
        embedder.maybePassTest();
      } else {
        window.console.log('Unexpected message: ' + e.message);
      }
    });
  });
}
function startCheckTest ( testName ) { chrome . test . getConfig ( function ( config ) { embedder . baseGuestURL = 'http://localhost:' + config . testServer . port ; embedder . guestURL = embedder . baseGuestURL + '/extensions/platform_apps/web_view/media_access' + '/media_check_guest.html' ; chrome . test . log ( 'Guest url is: ' + embedder . guestURL ) ; var webview = embedder . setUpGuest_ ( ) ; if ( ! webview ) { return ; } embedder . setUpLoadStop_ ( webview ) ; webview . addEventListener ( 'consolemessage' , function ( e ) { window . console . log ( e . message ) ; } ) ; window . addEventListener ( 'message' , function ( e ) { var data = JSON . parse ( e . data ) ; if ( data [ 0 ] == 'got-sources' ) { embedder . maybePassTest ( ) ; } else { window . console . log ( 'Unexpected message: ' + e . message ) ; } } ) ; } ) ; }
Entry point for test, called by WebViewTest.
Entry point for test called by WebViewTest .