def test_sort_by_tester(self):
        self.factory(tester__username="Tester 1")
        self.factory(tester__username="Tester 2")

        res = self.get(
            params={"sortfield": "tester__username", "sortdirection": "desc"}
            )

        self.assertOrderInList(res, "Tester 2", "Tester 1")
Can sort by tester.
dataset/ETHPy150Open mozilla/moztrap/tests/view/results/results/test_views.py/ResultsViewTest.test_sort_by_tester