JAKARTA (AFP) - An Indonesian court is expected to uphold Joko Widodo's victory in last month's presidential election, rejecting claims of widespread cheating from his opponent after weeks of political uncertainty in the world's third-biggest democracy.
Ahead of the Constitutional Court ruling on Thursday, hundreds of supporters of Prabowo Subianto, the ex-general who lost the election, were staging noisy rallies in Jakarta while police and soldiers were out in force around the capital.
"I believe that Prabowo is the true president," said Dalianto, a 57-year-old supporter at a rally in downtown Jakarta. "The election commission cheated in their count of the votes."
The court is set to hand down its ruling on Thursday afternoon after two weeks of hearings, with independent analysts expecting the nine-judge panel to reject Prabowo's challenge. The verdict cannot be appealed.
Both Prabowo, a top military figure in the era of dictator Suharto with a chequered human rights record, and Widodo, the reform-minded governor of Jakarta, declared victory at the July 9 election.
However official results released after a two-week count across the vast archipelago showed Widodo won a decisive, six-point victory after the tightest, most polarising election since authoritarian rule ended in 1998.
The 53-year-old, who won legions of fans with his down-to-earth approach as Jakarta governor and is known by his nickname Jokowi, is the country's first leader from outside the political and military elites.
However Prabowo - who has been seeking the presidency for a decade - has refused to accept the results and his team filed a lengthy complaint against the election commission with the Constitutional Court, which has the final say on poll disputes.
They say he is the true winner of the election, that fraud occurred at tens of thousands of polling stations, and that election officials failed to order recounts in numerous places where they should have.
However evidence presented by Prabowo's team has not been regarded as convincing.
"They are going to throw out the suit," said Tobias Basuki, a political analyst from Jakarta-based think-tank the Centre for Strategic and International Studies, adding that the evidence was "very weak".
Legal challenges were mounted after Indonesia's two previous direct presidential elections, in 2004 and 2009, and both failed. The huge team of lawyers for Prabowo, now a wealthy businessman, has been left red-faced at times by unconvincing witness testimony.
One witness claimed to be a village girl from the mountains who supported Prabowo - only for it to emerge later that she held a senior position with the ex-general's party in eastern Papua province.
Security was tight ahead of the court announcement, with around 4,000 police on duty at the court and roads leading up to the building blocked off.
Supporters have been staging rallies at the court over the past two weeks, although they have been peaceful. Another 30,000 security personnel, including soldiers and police, will be deployed around the capital.
A spokesman for outgoing President Susilo Bambang Yudhoyono said that the leader hoped the ruling "will be accepted by all the Indonesian people".
Even if he loses, Prabowo has pledged to fight on, telling supporters this week that "our struggle has just started".
But analysts believe he has no other realistic options left to challenge the result.
A loss for Prabowo in court would clear the way for Widodo to focus on forming his administration and formulating policy before his Oct 20 inauguration. He has already set up a "transition team" to shape policy and pick his cabinet, and asked the public to suggest who they would like to be ministers in an online poll.