@Test public void testUpdateExisting() throws Exception { long pk = ServiceTestUtil.nextLong(); ExportImportConfiguration newExportImportConfiguration = _persistence.create(pk); newExportImportConfiguration.setMvccVersion(ServiceTestUtil.nextLong()); newExportImportConfiguration.setGroupId(ServiceTestUtil.nextLong()); newExportImportConfiguration.setCompanyId(ServiceTestUtil.nextLong()); newExportImportConfiguration.setUserId(ServiceTestUtil.nextLong()); newExportImportConfiguration.setUserName(ServiceTestUtil.randomString()); newExportImportConfiguration.setCreateDate(ServiceTestUtil.nextDate()); newExportImportConfiguration.setModifiedDate(ServiceTestUtil.nextDate()); newExportImportConfiguration.setName(ServiceTestUtil.randomString()); newExportImportConfiguration.setDescription(ServiceTestUtil.randomString()); newExportImportConfiguration.setType(ServiceTestUtil.nextInt()); newExportImportConfiguration.setSettings(ServiceTestUtil.randomString()); newExportImportConfiguration.setStatus(ServiceTestUtil.nextInt()); newExportImportConfiguration.setStatusByUserId(ServiceTestUtil.nextLong()); newExportImportConfiguration.setStatusByUserName(ServiceTestUtil.randomString()); newExportImportConfiguration.setStatusDate(ServiceTestUtil.nextDate()); _persistence.update(newExportImportConfiguration); ExportImportConfiguration existingExportImportConfiguration = _persistence.findByPrimaryKey(newExportImportConfiguration.getPrimaryKey()); Assert.assertEquals( existingExportImportConfiguration.getMvccVersion(), newExportImportConfiguration.getMvccVersion()); Assert.assertEquals( existingExportImportConfiguration.getExportImportConfigurationId(), newExportImportConfiguration.getExportImportConfigurationId()); Assert.assertEquals( existingExportImportConfiguration.getGroupId(), newExportImportConfiguration.getGroupId()); Assert.assertEquals( existingExportImportConfiguration.getCompanyId(), newExportImportConfiguration.getCompanyId()); Assert.assertEquals( existingExportImportConfiguration.getUserId(), newExportImportConfiguration.getUserId()); Assert.assertEquals( existingExportImportConfiguration.getUserName(), newExportImportConfiguration.getUserName()); Assert.assertEquals( Time.getShortTimestamp(existingExportImportConfiguration.getCreateDate()), Time.getShortTimestamp(newExportImportConfiguration.getCreateDate())); Assert.assertEquals( Time.getShortTimestamp(existingExportImportConfiguration.getModifiedDate()), Time.getShortTimestamp(newExportImportConfiguration.getModifiedDate())); Assert.assertEquals( existingExportImportConfiguration.getName(), newExportImportConfiguration.getName()); Assert.assertEquals( existingExportImportConfiguration.getDescription(), newExportImportConfiguration.getDescription()); Assert.assertEquals( existingExportImportConfiguration.getType(), newExportImportConfiguration.getType()); Assert.assertEquals( existingExportImportConfiguration.getSettings(), newExportImportConfiguration.getSettings()); Assert.assertEquals( existingExportImportConfiguration.getStatus(), newExportImportConfiguration.getStatus()); Assert.assertEquals( existingExportImportConfiguration.getStatusByUserId(), newExportImportConfiguration.getStatusByUserId()); Assert.assertEquals( existingExportImportConfiguration.getStatusByUserName(), newExportImportConfiguration.getStatusByUserName()); Assert.assertEquals( Time.getShortTimestamp(existingExportImportConfiguration.getStatusDate()), Time.getShortTimestamp(newExportImportConfiguration.getStatusDate())); }