def test_foreign_key_with_empty(self):
        serializer = NullableForeignKeySourceSerializer()
        self.assertEqual(serializer.data['target'], None)
Regression test for #1072
dataset/ETHPy150Open tomchristie/django-rest-framework/tests/test_relations_pk.py/PKForeignKeyTests.test_foreign_key_with_empty