@Test
  public void testResetOriginalValues() throws Exception {
    if (!PropsValues.HIBERNATE_CACHE_USE_SECOND_LEVEL_CACHE) {
      return;
    }

    PasswordPolicy newPasswordPolicy = addPasswordPolicy();

    _persistence.clearCache();

    PasswordPolicyModelImpl existingPasswordPolicyModelImpl =
        (PasswordPolicyModelImpl) _persistence.findByPrimaryKey(newPasswordPolicy.getPrimaryKey());

    Assert.assertEquals(
        existingPasswordPolicyModelImpl.getCompanyId(),
        existingPasswordPolicyModelImpl.getOriginalCompanyId());
    Assert.assertEquals(
        existingPasswordPolicyModelImpl.getDefaultPolicy(),
        existingPasswordPolicyModelImpl.getOriginalDefaultPolicy());

    Assert.assertEquals(
        existingPasswordPolicyModelImpl.getCompanyId(),
        existingPasswordPolicyModelImpl.getOriginalCompanyId());
    Assert.assertTrue(
        Validator.equals(
            existingPasswordPolicyModelImpl.getName(),
            existingPasswordPolicyModelImpl.getOriginalName()));
  }
  @Override
  public void resetOriginalValues() {
    PasswordPolicyModelImpl passwordPolicyModelImpl = this;

    passwordPolicyModelImpl._originalUuid = passwordPolicyModelImpl._uuid;

    passwordPolicyModelImpl._originalCompanyId = passwordPolicyModelImpl._companyId;

    passwordPolicyModelImpl._setOriginalCompanyId = false;

    passwordPolicyModelImpl._setModifiedDate = false;

    passwordPolicyModelImpl._originalDefaultPolicy = passwordPolicyModelImpl._defaultPolicy;

    passwordPolicyModelImpl._setOriginalDefaultPolicy = false;

    passwordPolicyModelImpl._originalName = passwordPolicyModelImpl._name;

    passwordPolicyModelImpl._columnBitmask = 0;
  }