Now that you're using rewire, it seems like you could just access this the same way (`repository.__get__("metadata")`) instead of exposing it directly from the module.