function testGetReversed_Add() {
  var original = new lf.cache.TableDiff(table.getName());
  var row1 = table.createRow({'id': 'pk1', 'name': 'DummyName'});
  row1.assignRowId(1);
  var row2 = table.createRow({'id': 'pk2', 'name': 'DummyName'});
  row2.assignRowId(2);
  original.add(row1);
  original.add(row2);

  assertEquals(2, original.getAdded().size);
  assertEquals(0, original.getModified().size);
  assertEquals(0, original.getDeleted().size);

  var reverse = original.getReverse();
  assertEquals(0, reverse.getAdded().size);
  assertEquals(0, reverse.getModified().size);
  assertEquals(2, reverse.getDeleted().size);

  assertSameElements(
      lf.structs.map.keys(original.getAdded()),
      lf.structs.map.keys(reverse.getDeleted()));
}
Testing reversing a diff with only additions.