function verifyLayout(rows) {
  var rowIndex = 1;
  rows.forEach(function(sequence) {
    var rowId = 'row' + rowIndex++;
    var first = sequence[0];
    var key = findKey(first, rowId);
    assertTrue(!!key, 'Unable to find "' + first + '" in "' + rowId + '"');
    key = getSoftKeyView(key);
    for (var i = 1; i < sequence.length; i++) {
      var next = key.nextSibling;
      assertTrue(
          !!next, 'Unable to find key to right of "' + sequence[i - 1] + '"');
      assertTrue(
          hasLabel(next, sequence[i]),
          'Unexpected label: expected: "' + sequence[i] + '" to follow "' +
              sequence[i - 1] + '"');
      key = next;
    }
  });
}
/**
 * Verifies that the layout matches with expectations.
 * @param {Array<string>} rows List of strings where each string indicates the
 *     expected sequence of characters on the corresponding row.
 */
Verifies that the layout matches with expectations.
@param {Array} rows List of strings where each string indicates the
expected sequence of characters on the corresponding row.
Verifies that the layout matches with expectations . @param { Array } rows List of strings where each string indicates the expected sequence of characters on the corresponding row .
function verifyLayout(rows) {
  var rowIndex = 1;
  rows.forEach(function(sequence) {
    var rowId = 'row' + rowIndex++;
    var first = sequence[0];
    var key = findKey(first, rowId);
    assertTrue(!!key, 'Unable to find "' + first + '" in "' + rowId + '"');
    key = getSoftKeyView(key);
    for (var i = 1; i < sequence.length; i++) {
      var next = key.nextSibling;
      assertTrue(
          !!next, 'Unable to find key to right of "' + sequence[i - 1] + '"');
      assertTrue(
          hasLabel(next, sequence[i]),
          'Unexpected label: expected: "' + sequence[i] + '" to follow "' +
              sequence[i - 1] + '"');
      key = next;
    }
  });
}
function verifyLayout ( rows ) { var rowIndex = 1 ; rows . forEach ( function ( sequence ) { var rowId = 'row' + rowIndex ++ ; var first = sequence [ 0 ] ; var key = findKey ( first , rowId ) ; assertTrue ( ! ! key , 'Unable to find "' + first + '" in "' + rowId + '"' ) ; key = getSoftKeyView ( key ) ; for ( var i = 1 ; i < sequence . length ; i ++ ) { var next = key . nextSibling ; assertTrue ( ! ! next , 'Unable to find key to right of "' + sequence [ i - 1 ] + '"' ) ; assertTrue ( hasLabel ( next , sequence [ i ] ) , 'Unexpected label: expected: "' + sequence [ i ] + '" to follow "' + sequence [ i - 1 ] + '"' ) ; key = next ; } } ) ; }
Verifies that the layout matches with expectations.
Verifies that the layout matches with expectations .