testOptimisticLock test added and version annotation used.