def test_retrieve_spls(self):
    'Test retrieving spls'
    res = self.client.get(SPL_URL, format='json')
    serializer = SplSerializer(Spl.objects.filter(), many=True)
    self.assertEqual(res.status_code, status.HTTP_200_OK)
    self.assertEqual(serializer.data, res.data['results'])
Test retrieving spls
def test_retrieve_spls(self):
    
    res = self.client.get(SPL_URL, format='json')
    serializer = SplSerializer(Spl.objects.filter(), many=True)
    self.assertEqual(res.status_code, status.HTTP_200_OK)
    self.assertEqual(serializer.data, res.data['results'])