@Test
public void testSetTitle() throws Exception {

  final String NEW_TITLE = "___NEW_TITLE___";
  RDBMSTestFactory factory = new RDBMSTestFactory();
  TopicMapReferenceIF before = factory.makeTopicMapReference();
  Assert.assertNotSame("Test reference already has title '" + NEW_TITLE + "', cannot test for change", NEW_TITLE, before.getTitle());
  before.setTitle(NEW_TITLE);
  String referenceId = before.getId();
  factory = new RDBMSTestFactory(); // reload
  TopicMapReferenceIF after = null;
  for (TopicMapReferenceIF i : factory.getSource().getReferences()) {
    if (referenceId.equals(i.getId())) { after = i; }
  }
  Assert.assertNotNull("Reference with id '" + referenceId + "' not found", after);
  Assert.assertEquals("Reference title not changed correctly", NEW_TITLE, after.getTitle());
}