public int CreateOrUpdate(Test entity, bool commit = false) { testRepository.CreateOrUpdate(entity); return(commit ? unitOfWork.Commit() : -1); }