#NEWLINE# def test_startswith_generates_the_right_expression_for_the_startswith_lookup_when_comparing_to_a_field( self ) : #NEWLINE# #INDENT# field1 = NaturalQueryDescriptor ( 'field1' ) #NEWLINE# field2 = NaturalQueryDescriptor ( 'field2' ) #NEWLINE# expected = Q ( field1__startswith = F ( 'field2' ) ) #NEWLINE# actual = field1 . startswith ( field2 ) #NEWLINE# self . assertEqual ( actual , expected )