function testRowIdsUnique() {
  if (!capability.indexedDb)
    return Promise.resolve();

  lf.Row.setNextId(0);

  var schemaBuilder1 = lf.schema.create('db1', 1);
  schemaBuilder1.createTable('TableA').
      addColumn('name', lf.Type.STRING);

  var schemaBuilder2 = lf.schema.create('db2', 1);
  schemaBuilder2.createTable('TableB').
      addColumn('name', lf.Type.STRING);

  /** @return {!Array<!lf.Row>} */
  function createNewTableARows() {
    var rows = [];
    var tableA = schemaBuilder1.getSchema().table('TableA');
    for (var i = 0; i < 3; i++) {
      rows.push(tableA.createRow({'name': 'name_' + i}));
    }
    return rows;
  }

  var options = {storeType: lf.schema.DataStoreType.INDEXED_DB};
  return schemaBuilder1.connect(options).then(function() {
    var rows = createNewTableARows();
    assertArrayEquals(
        [1, 2, 3],
        rows.map(function(r) { return r.id(); }));
  }).then(function() {
    return schemaBuilder2.connect(options);
  }).then(function() {
    var rows = createNewTableARows();
    assertArrayEquals(
        [4, 5, 6],
        rows.map(function(r) { return r.id(); }));
  });
}
Tests that connecting to a 2nd database does not cause lf.Row.nextId_ to be
overwritten with a smaller value (which guarantees that row IDs will remain
unique).
@return {!IThenable}
@suppress {accessControls}