BRASILIA (Reuters) - Brazil’s top electoral court opens a trial on Tuesday over the alleged use of illicit money to fund President Michel Temer’s 2014 election campaign in a case that could force him from office.

Brazil's President Michel Temer gestures during a inauguration ceremony of the new Minister of Justice, Torquato Jardim, at the Planalto Palace, in Brasilia, Brazil May 31, 2017. REUTERS/Ueslei Marcelino

The court has no deadline to reach a decision and could take weeks to rule, though the political turmoil Brazil is living through as it faces the potential second ouster of a president in a year will put pressure on the judges to reach a conclusion quickly.

If found guilty, Temer is expected to appeal and delay the process for months. Such a ruling would likely destabilize his government and prompt members of his coalition to withdraw their support, increasing chances he could be forced to resign.

The main ally in his governing coalition, the Brazilian Social Democracy Party (PSDB), is waiting for the court ruling to decide whether to abandon Temer’s government, which would sink his fiscal reform agenda.

The reforms, particularly an overhaul of Brazil’s costly pension system, are crucial for plugging a gaping budget deficit that cost Brazil its investment grade credit rating in 2015 and helped push Latin America’s largest economy into its worst recession on record.

In four sessions scheduled through Friday, the seven-member electoral court will discuss whether to annul the 2014 re-election victory of then-President Dilma Rousseff and her running mate, Temer, who became president last year when Rousseff was impeached for breaking budget laws.

If the court, known by its TSE Portuguese initials, invalidates the 2014 election, lower house Speaker Rodrigo Maia would take over from Temer and Congress would have 30 days to pick a caretaker to lead the country until elections in 2018.

Brazil’s constitution has no clear rules for such a presidential eviction, and in such an unprecedented situation, the court would have to decide whether Temer can continue in office pending an appeal.

Most analysts expect a member of the court to request a delay to study the case further, which would win Temer time to try to rebuild his political base and avoid an exodus of allies.

“The TSE will decide the fate of Temer and the reforms,” said Rafael Cortez, a political and economic analyst with Tendencias consultancy in Sao Paulo. “The court will rule whether he gets more time to recover his ability to govern.”

Cortez said a PSDB exit from the coalition would doom Temer because the party’s support has given his economic policies credibility among investors and Brazil’s elite.

A presidential spokesman said Temer had huddled with his lawyers over the weekend to go over his line of defense, which will argue that the ticket had separate accounts and Rousseff’s campaign was responsible for receiving illegal donations.

But it is unlikely the court would accept that argument based on recent plea-bargain testimony by executives of giant meatpacker JBS SA, as well as construction firm Odebrecht saying it had agreed to pay millions in illegal campaign funding with Temer or his top aides.

Temer has refused to resign after the Supreme Court late last month authorized an investigation of the president for alleged corruption, criminal organization and obstruction of justice based on a secret recording of a conversation with a JBS executive in which he appeared to agree to the payment of hush money to silence a key witness in a massive graft scandal.

The political crisis engulfing Temer’s government deepened on Saturday with the arrest of a close aide who was seen in a police video receiving a bag filled with 500,000 reais ($152,000) in cash.

Adding to calls for his resignation or impeachment, the country’s largest circulation daily, the Folha de S.Paulo, recommended in an editorial on Sunday that the TSE invalidate the Rousseff-Temer ticket and that he be removed from office.

“The imminent TSE ruling provides a legal formula to remove a head of state whose situation has become indefensible,” the newspaper said.