Hello I am brand new to unit testing and I just cant wrap my head around it. This is the simplest function I need to test and I am clueless as how to even do that. I know I need to pass a mock request object I think but beyond that I'm pretty lost. Could use some guidance.
def get_all_zones(request):
user = request.user
all_site = get_objects_for_user(user, 'sitehotspot_portal', klass=SiteHotspot).values_list('uid', 'name')
all_site = [list(i) for i in all_site]
all_area = get_objects_for_user(user, 'areashotspot_portal', klass=AreasHotspot).values_list('uid', 'name')
all_area = [list(i) for i in all_area]
all_sphere = get_objects_for_user(user, 'spherehotspot_portal', klass=SphereHotspot).values_list('uid', 'name')
all_sphere = [list(i) for i in all_sphere]
all_zones = all_area + all_site + all_sphere
return(all_zones)```