Hungary’s Constitutional Court is expected to rule on a government motion challenging the supremacy of European Union law on Friday, Prime Minister Viktor Orban told public radio.

The court has been considering a challenge by Orban’s justice minister, Judit Varga, to an EU court finding that Budapest had broken EU laws designed to protect refugees by deporting them to the Serbian border.

Neighbouring Poland’s Constitutional Tribunal sparked a crisis in the 27-member bloc earlier this year by finding that parts of the bloc’s treaties were incompatible with the Polish constitution.

Varga argues that implementing the ruling by the European Court of Justice would result in many migrants staying in Hungary permanently.

Orban, one of the most strident opponents of mass immigration to Europe from the Middle East and Asia, held a referendum in 2016 against an EU scheme to settle migrants in member states, which Hungarian voters overwhelmingly opposed.

“The question is whether this goes against the rules of Brussels, and now that we have a situation where Hungarian rules opposing immigration are opposed to the decisions of Brussels’ bureaucrats and courts, what should be done,” Orban said.

“The interpretation of the Hungarian constitution, for example with regard to a row with Brussels, should fall to the (Hungarian) Constitutional Court in the last instance,” he said.

In power since 2010, Orban has relished conflict with EU institutions, portraying himself as a champion of Hungary’s national interests.

The 58-year-old looks set to face a strong challenge in next year’s election, and conflict with Brussels over immigration could provide fodder for him to campaign on an issue that has previously helped him to shore up his support.

Orban said if the court ruled in favour of his government, he would push for the EU to reform its rules on immigration.

“The reality of immigration is not in Brussels, but on the Hungarian border, the Polish border and in the ports of Italy,” Orban said. “We need to tackle the problems that have emerged, and change the rules.”