@pytest.mark.parametrize(u'collection', [[u'user_action', u'user'], [u'user_group', u'user'], [u'user_group', u'user_action']])
def test_should_break_ties_using_lexical_order(completer, collection):
 text = u'user'
 matches = completer.find_matches(text, collection)
 assert (matches[1].priority > matches[0].priority)

@ pytest . mark . parametrize ( u'collection' , [ [ u'user_action' , u'user' ] , [ u'user_group' , u'user' ] , [ u'user_group' , u'user_action' ] ] ) def test_should_break_ties_using_lexical_order ( completer , collection ) : text = u'user' matches = completer . find_matches ( text , collection ) assert ( matches [ 1 ] . priority > matches [ 0 ] . priority )
fuzzy result rank should use lexical order to break ties .