Fix test: repository permissions and pass id.