'Ensure no superfluous queries are made when serializing ForeignKeys
#17602'

def test_serialize_superfluous_queries(self):

    ac = Actor(name=u'Actor    name')
    ac.save()
    mv = Movie(title=u'Movie    title', actor_id=ac.pk)
    mv.save()
    with self.assertNumQueries(0):
        serial_str = serializers.serialize(self.serializer_name, [mv])
