  from rest_framework import generics, status, permissions, authentication, HTTP_HEADER_ENCODING
  from rest_framework.compat import guardian
  from rest_framework.test import APIRequestFactory
  from rest_framework.tests.models import BasicModel
  from rest_framework.settings import api_settings
  import base64
  
  factory = APIRequestFactory()
  
  class RootView(generics.ListCreateAPIView):
 
</s> remove from django.contrib.auth.models import User, Permission
 </s> add from django.contrib.auth.models import User, Permission, Group </s> remove             # assign permissions appropriately
            from guardian.shortcuts import assign_perm
 </s> add             # appropriate object level permissions
            readers = Group.objects.create(name='readers')
            writers = Group.objects.create(name='writers')
            deleters = Group.objects.create(name='deleters')
  from rest_framework import generics, status, permissions, authentication, HTTP_HEADER_ENCODING
  from rest_framework.compat import guardian
  from rest_framework.test import APIRequestFactory
  from rest_framework.tests.models import BasicModel

  import base64
  
  factory = APIRequestFactory()
  
  class RootView(generics.ListCreateAPIView):
keep keep keep keep replace keep keep keep keep keep
 first pass at object level permissions and tests 
rest_framework/tests/test_permissions.py