repository findById with tests