Le Pen shared the gruesome images in December 2015, a few weeks after IS jihadists killed 130 people in attacks in Paris, sparking widespread condemnation in France.

The 50-year-old leader of the National Rally (formerly the National Front), who lost to Emmanuel Macron in last year’s presidential vote, was stripped of her parliamentary immunity over the pictures and charged with circulating violent messages that can be viewed by minors.

On Thursday, she tweeted copies of a court order requiring her to undergo a psychiatric evaluation.

Dated September 11, it calls for the tests to be carried out “as soon as possible” to establish whether Le Pen “is capable of understanding remarks and answering questions”.

“It’s crazy,” fumed Le Pen, herself a trained lawyer.

“I thought I had been through it all: well, no! For having condemned Daesh (IS) horrors in tweets, the ‘justice system’ is putting me through psychiatric tests! Just how far will they go?” she asked, repeating her view that it was part of a government plot to discredit her.

‘I won’t go!’

Speaking to reporters in the halls of the National Assembly, Le Pen said she felt “persecuted” by the state and would defy the order.

“Of course I won’t go and submit myself to this psychiatric evaluation,” she declared, daring the investigating magistrate to “force” her.

Under French law there is no legal mechanism for forcing a person to comply with such an order.

The prosecutor’s office in the Paris suburb of Nanterre, where the court is located, said such tests were routine in cases involving the dissemination of violent messages.

But there were howls of indignation from Le Pen’s supporters and allies.

“A prosecutor has ordered psychiatric tests on Marine Le Pen. There are no words. Solidarity with her and those French people who love liberty,” wrote Salvini, whose League party is in an alliance with Le Pen’s faction.

Her father Jean-Marie Le Pen, who founded the National Front before being pushed out by his daughter as she sought to marginalise his more inflammatory style, came to her support.

“The insolence of some magistrates has no limits,” he said of the ruling.

Donald Trump’s former adviser Steve Bannon, who wants to form a pan-European right-wing movement, said in a statement: “I’ve said for years that when the elites can’t beat your ideas, they try to beat you down as a person — to call into question your trustworthiness or intelligence or stability.”

“The psychiatrisation of political opposition was a common tactic in the USSR, reflecting more on the sickness of the regime than its target,” he added.

Even some of Le Pen’s fiercest opponents also expressed misgivings about the tests.

Her leftist nemesis Jean-Luc Melenchon, the France Unbowed leader who once called Le Pen “half-demented”, tweeted his “total disagreement” with the court order.

“It’s not these kind of methods that will drive back the far right,” wrote Melenchon.

Party ‘risks death’

Le Pen shared the IS images in response to a French journalist who drew a comparison between the jihadist group and her party.

One of the pictures showed the body of James Foley, an American journalist beheaded by the Sunni extremists.

Another showed a man in an orange jumpsuit being run over by a tank and the third showed a Jordanian pilot being burned alive in a cage.

“Daesh is this!” Le Pen wrote in a caption, using an Arabic acronym for IS.

She later deleted the picture of Foley after a request from his family, saying she had been unaware of his identity, but she has denounced the case against her as a violation of her freedom of expression.

If convicted, she faces up to three years in prison and a fine of 75,000 euros ($87,000).

Another National Rally lawmaker, lawyer Gilbert Collard, has also been charged for tweeting pictures of IS atrocities.

The furore over the psychiatric tests comes as Le Pen attempts to rally support for her cash-strapped party ahead of European elections next spring, in which she is hoping to rebound from her presidential defeat.

Last week, she repeated warnings that her party’s existence was at stake if it didn’t manage to win back two million euros in subsidies seized as part of an inquiry into claims it misused millions’ worth of European Parliament funds.