@Override
  public void start() {
    LoggerFactory.getLogger(RenameDeprecatedPropertyKeys.class).info("Rename deprecated property keys");
    for (PropertyDefinition definition : definitions.getAll()) {
      if (!Strings.isNullOrEmpty(definition.deprecatedKey())) {
        dao.renamePropertyKey(definition.deprecatedKey(), definition.key());
      }
    }
  }
@Test
  public void should_rename_deprecated_keys() {
    PropertiesDao dao = mock(PropertiesDao.class);
    PropertyDefinitions definitions = new PropertyDefinitions(System2.INSTANCE, FakeExtension.class);
    RenameDeprecatedPropertyKeys task = new RenameDeprecatedPropertyKeys(dao, definitions);
    task.start();

    verify(dao).renamePropertyKey("old_key", "new_key");
    verifyNoMoreInteractions(dao);
  }