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

Conflicts:

	repository/tests/repository_test.php