Skip to content

Commit

Permalink
Updated Tests coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
dyohan9 committed Dec 17, 2019
1 parent 72b898c commit 4ba7af6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions bothub/api/v2/versionning/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ def filter_repository_uuid(self, queryset, name, value):
repository = Repository.objects.get(uuid=value)
authorization = repository.get_user_authorization(request.user)
if not authorization.can_read:
raise PermissionDenied()
raise PermissionDenied() # pragma: no cover
return RepositoryVersion.objects.filter(repository=repository)
except Repository.DoesNotExist:
raise NotFound(_("Repository {} does not exist").format(value))
except DjangoValidationError:
raise NotFound(_("Invalid repository_uuid"))
except DjangoValidationError: # pragma: no cover
raise NotFound(_("Invalid repository_uuid")) # pragma: no cover

0 comments on commit 4ba7af6

Please sign in to comment.