MDL-38498 repository: Unit tests for repository::check_capability()