#NEWLINE# def test_reverse_relation_pk( self ) : #NEWLINE# #INDENT# '\n        Test that the correct column name is used for the primary key on the\n        originating model of a query.  See #12664.\n        ' #NEWLINE# p = Person . objects . create ( account = 23 , name = 'Chef' ) #NEWLINE# Address . objects . create ( street = '123 Anywhere Place' , city = 'Conifer' , state = 'CO' , zipcode = '80433' , content_object = p ) #NEWLINE# qs = Person . objects . filter ( addresses__zipcode = '80433' ) #NEWLINE# self . assertEqual ( 1 , qs . count ( ) ) #NEWLINE# self . assertEqual ( 'Chef' , qs [ 0 ] . name )