def METHOD_NAME(self, mock_call_url):
    """Assert we handle getting non-JSON responses gracefully"""
    mock_call_url.return_value.json.side_effect = ValueError
    project = models.Project.by_id(self.session, 1)
    with self.assertRaises(AnityaPluginException) as context_manager:
        crates.CratesBackend._get_versions(project)  # pylint: disable=W0212
        self.assertIn("Failed to decode JSON", str(context_manager.exception))