IT WAS the day Mary Queen of Scots was deposed, ending a reign of almost 25 years.

Now Nicola Sturgeon and Theresa May will be hoping July 24 is less ominous for modern leaders, as their governments go to court over a Brexit “power grab”.

The Supreme Court has provisionally set down July 24 and 25 for the unprecedented legal clash, in which the UK government will effectively seek to kill off a Bill passed by Holyrood.

Although the timing coincides with Westminster going into summer recess, the event is expected to become a highly politicised part of the independence debate.

READ MORE: Shoppers face higher food bills if no Brexit trade deal agreed with EU, warn peers

The two governments will argue about the validity of a Holyrood Bill designed to be an alternative to Westminster’s main Brexit legislation, the EU Withdrawal Bill.

MSPs passed the SNP-led Continuity Bill by 92 votes to 32 in March as a fallback, in case the UK government failed to remove a “power grab” clause from the Withdrawal Bill.

London later changed the Bill enough to placate the Welsh government, but SNP ministers still oppose it as it gives Westminster the last word in 24 devolved areas after Brexit.

If, as expected, MSPs withhold legislative consent for the Withdrawal Bill next week, the fate of the Holyrood alternative will be decided by the Supreme Court.

Holyrood Presiding Officer Ken Macintosh warned in February that he believed the Continuity Bill was ultra vires as it strayed into EU law.

However MSPs rejected his advice - a first for devolution - after the Scottish Government’s top law officer, the Lord Advocate James Wolffe QC, assured them it was competent.

The UK government last month referred the Bill to the Supreme Court for a definitive ruling.

The Court said the case would be heard by five or seven justices.

A spokeswoman added: “The case has been provisionally listed for 24 and 25 July 2018.”

READ MORE: Theresa May gets support on customs plan after Leo Varadkar says it could be 'workable'

Scottish Secretary David Mundell and Brexit minister Robin Walker are due to give evidence on Brexit to Holyrood’s Europe committee today.

If the Supreme court rules the Holyrood Bill is incompetent it would be deemed “not law” and void.

That would be embarrassing for Ms Sturgeon, although Mr May would still be left with the constitutional problem of Holyrood withholding its consent for the EU Withdrawal Bill.

Ultimately, the UK government would be likely to impose its own Brexit law on Scotland.

If the Court backed the Continuity Bill, the UK could also impose its own Brexit law, but at a higher political price, as it would mean trampling on a Holyrood law.