ISTANBUL/ANKARA (Reuters) - Turkey cast the testimony of a wealthy gold trader in a U.S. court as an attempt to undermine Ankara and its economy on Friday, highlighting how President Tayyip Erdogan may use the politically charged case to rally nationalist support.

FILE PHOTO: Turkish President Tayyip Erdogan addresses members of parliament from his ruling AK Party (AKP) during a meeting at the Parliament in Ankara, Turkey, November 7, 2017. REUTERS/Umit Bektas/File Photo

The trader, Reza Zarrab, told a New York court on Wednesday that Erdogan had authorized a transaction in a scheme to help Iran evade U.S. sanctions. A dual national of Iran and Turkey, Zarrab is cooperating with U.S. prosecutors in the trial of a Turkish bank executive accused of helping Iran launder money. The executive has pleaded not guilty.

“This court case has stopped being judicial and become completely political, with the sole aim to corner Turkey and its economy,” Prime Minister Binali Yildirim said.

The case has aggravated tension between Ankara and Washington, NATO allies already at odds over Syria policy and the United States’ failure to extradite the Muslim cleric Turkey accuses of engineering a failed military coup last year.

Although the economic fall-out from the case could be substantial - especially if U.S. authorities fine Turkish banks - analysts said that Erdogan is unlikely to be damaged politically at home and could potentially emerge stronger by attracting more nationalist support.

“This will bolster his claim that he is fighting an independence battle against foreign enemies,” said Halil Karaveli, editor of the Turkey Analyst, a policy journal.

“If there is going to be any political impact, I suspect it will actually help in the electoral sense.”

Media coverage of the case has been limited in Turkey and one pro-government outlet branded the trial as a conspiracy by “enemies” of the country.

ECONOMIC IMPACT

Erdogan, who has governed Turkey for almost 15 years, has not yet responded to the courtroom claims; but had already dismissed the case as a politically inspired attempt to bring down the Turkish government.

His government says the network of U.S.-based cleric Fethullah Gulen, blamed by Ankara for the failed military coup, was also behind the court case.

“Zarrab’s deposition before the U.S. court will not impact the outlook of the AK Party constituency. In return, mitigating the possible economic impact will be more of a challenge especially if Turkish banks are eventually fined,” said Sinan Ulgen, an analyst and former Turkish diplomat.

International investors have grown nervous about Turkey as ties with the United States have worsened - helping drive the lira currency down some 10 percent against the dollar in the past three months, to a series of record lows.

But the U.S. legal action over the alleged Iran sanctions busting, and the risk that some of the country’s banks might be sucked into the case, lies at the heart of the latest investor concerns.

U.S. prosecutors charge that the executive of Turkey’s state-owned Halkbank, Mehmet Hakan Atilla, helped Iran launder the money. Halkbank, like Atilla, has said it is not guilty of the charges. In his testimony, Zarrab also said that Turkish officials had authorized two Turkish banks, Ziraat Bank and VakifBank, to move funds for Iran.

Both Ziraat and VakifBank have denied taking part in any such scheme.

Nonetheless, investors are worried about the possibility that Turkish banks could be fined.

“If there is a fine that’s outsize and the Turkish government doesn’t want to pay or allow the bank to pay, it will turn into a political standoff which is not great for banks or sovereign spreads,” said Greg Saichin, head of emerging debt at Allianz Global Investors in London.

“This whole issue is weighing heavily on Turkey as a country to allocate (capital) to.”