* Test method for {@link models.OptimisticLockingModel.VersionedModel#setVersion(java.lang.Long)}.
*/
@Test
public void testSetVersion() {
final TestModel testModel = new TestModel();
final OptimisticLockingCheck check = new OptimisticLockingCheckWithoutMessage();
testModel.setVersion(Long.valueOf(2));
assertTrue(check.isSatisfied(testModel, ""));
testModel.setVersion(Long.valueOf(2));
assertTrue(check.isSatisfied(testModel, ""));
testModel.setVersion(Long.valueOf(3));
assertTrue(check.isSatisfied(testModel, ""));
testModel.setVersion(Long.valueOf(1));
assertFalse(check.isSatisfied(testModel, ""));
}