def test_change_priority_for_non_existing_item_in_filled_q(): q = [[2, 'item']] algorithm._change_priority(q, 2, 'item2') eq_(q, [[2, 'item'], [2, 'item2']])
def test_change_priority_for_existing_item(): q = [[1, 'item']] algorithm._change_priority(q, 2, 'item') eq_(q, [[2, 'item']])
def test_change_priority_for_non_existing_item_in_empty_q(): q = [] algorithm._change_priority(q, 2, 'item') eq_(q, [[2, 'item']])