function testLoadAbortInvalidNavigation() {
  var webview = document.createElement('webview');
  webview.addEventListener('loadabort', function(e) {
    embedder.test.assertEq(-300, e.code);
    embedder.test.assertEq('ERR_INVALID_URL', e.reason);
    embedder.test.assertEq('', e.url);
  });
  webview.addEventListener('loadstop', function(e) {
    embedder.test.assertEq('about:blank', webview.src);
    embedder.test.succeed();
  });
  webview.addEventListener('exit', function(e) {
    // We should not crash.
    embedder.test.fail();
  });
  webview.src = 'http:';
  document.body.appendChild(webview);
}
// Verifies that navigating to invalid URL (e.g. 'http:') doesn't cause a crash.
Verifies that navigating to invalid URL  doesn't cause a crash.
Verifies that navigating to invalid URL doesn ' t cause a crash .
function testLoadAbortInvalidNavigation() {
  var webview = document.createElement('webview');
  webview.addEventListener('loadabort', function(e) {
    embedder.test.assertEq(-300, e.code);
    embedder.test.assertEq('ERR_INVALID_URL', e.reason);
    embedder.test.assertEq('', e.url);
  });
  webview.addEventListener('loadstop', function(e) {
    embedder.test.assertEq('about:blank', webview.src);
    embedder.test.succeed();
  });
  webview.addEventListener('exit', function(e) {
    embedder.test.fail();
  });
  webview.src = 'http:';
  document.body.appendChild(webview);
}
function testLoadAbortInvalidNavigation ( ) { var webview = document . createElement ( 'webview' ) ; webview . addEventListener ( 'loadabort' , function ( e ) { embedder . test . assertEq ( - 300 , e . code ) ; embedder . test . assertEq ( 'ERR_INVALID_URL' , e . reason ) ; embedder . test . assertEq ( '' , e . url ) ; } ) ; webview . addEventListener ( 'loadstop' , function ( e ) { embedder . test . assertEq ( 'about:blank' , webview . src ) ; embedder . test . succeed ( ) ; } ) ; webview . addEventListener ( 'exit' , function ( e ) { embedder . test . fail ( ) ; } ) ; webview . src = 'http:' ; document . body . appendChild ( webview ) ; }
Verifies that navigating to invalid URL (e.g.
Verifies that navigating to invalid URL ( e . g .
// We should not crash.