Example #1
0
    def test_get_face_images_by_district_first_letter(self):
        face_image1 = self.create_face_image()
        face_image2 = self.create_face_image()

        face = face_image1.face
        face.district = DistrictFactory(district='Test District')
        face.images.add(face_image2)
        face.save()

        self.assertEqual(2, len(get_face_images_by_district_first_letter(face.first_letter_of_district())))
Example #2
0
File: views.py Project: taseew/pari
 def get_queryset(self):
     alphabet = self.kwargs['alphabet']
     return get_face_images_by_district_first_letter(alphabet)