B2G/gecko/browser/base/content/test/newtab/browser_newtab_focus.js
/*
 * These tests make sure that focusing the 'New Tage Page' works as expected.
 */
These tests make sure that focusing the 'New Tage Page' works as expected.
These tests make sure that focusing the ' New Tage Page ' works as expected .
function runTests() {
  Services.prefs.setIntPref("accessibility.tabfocus", 7);
  let FOCUS_COUNT = 28;
  yield setLinks("0,1,2,3,4,5,6,7,8");
  setPinnedLinks("");
  yield addNewTabPageTab();
  gURLBar.focus();
  yield countFocus(FOCUS_COUNT);
  NewTabUtils.allPages.enabled = false;
  yield countFocus(1);
  Services.prefs.clearUserPref("accessibility.tabfocus");
}
function runTests ( ) { Services . prefs . setIntPref ( "accessibility.tabfocus" , 7 ) ; let FOCUS_COUNT = 28 ; yield setLinks ( "0,1,2,3,4,5,6,7,8" ) ; setPinnedLinks ( "" ) ; yield addNewTabPageTab ( ) ; gURLBar . focus ( ) ; yield countFocus ( FOCUS_COUNT ) ; NewTabUtils . allPages . enabled = false ; yield countFocus ( 1 ) ; Services . prefs . clearUserPref ( "accessibility.tabfocus" ) ; }
These tests make sure that focusing the 'New Tage Page' works as expected.
These tests make sure that focusing the ' New Tage Page ' works as expected .
// Handle the OSX full keyboard access setting // Focus count in new tab page. // 28 = 9 * 3 + 1 = 9 sites and 1 toggle button, each site has a link, a pin // and a remove button. // Create a new tab page. // Count the focus with the enabled page. // Disable page and count the focus with the disabled page.