Imam ibn Taymiyah رحمہ اللہ said:
الجزاء في الدنيا متفق عليه أهل الأرض فإن الناس لم يتنازعوا في أن عاقبة الظلم وخيمة وعاقبة العدل كريمة، فإن الله لينصر الدولة العادلة وإن كانت كافرة ولا ينصر الدولة الظالمة وإن كانت مؤمنة".
Thus, people are agreed that outcome of oppression lead to dishonour and outcome of justice lead to honor and this is why it has been narrated:
Allah supports the rule of the justice even if it is ruled by disbelievers, and doesn't support the rule who oppresses even if it is run by Muslims.
[Majmo'o Al Fatawa 28/63]