Puerto Rico's Supreme Court on Monday agreed to rule on a lawsuit that the island's Senate filed in a bid to oust a veteran politician recently sworn in as the island's governor.

The court gave all parties until Tuesday at noon to file all necessary paperwork, noting that no extensions will be awarded.

The lawsuit seeks a preliminary injunction ordering Pedro Pierluisi to cease his functions immediately and also asks that the court declare unconstitutional a 2005 law that states a secretary of state does not have to be approved by both House and Senate if he has to step in as governor.

"We are a people of LAW and ORDER," Senate President Thomas Rivera Schatz wrote in a Facebook post. "There is no circumstance that places someone above the Law."

It is unclear how quickly the Supreme Court might rule or whether it would hold a hearing or simply issue a written opinion. The announcement comes as Puerto Ricans who successfully ousted the previous governor from office following nearly two weeks of protests await yet another twist in what is a deepening constitutional crisis.

Constitutional attorney Carlos Ramos told The Associated Press that the island's Supreme Court rarely holds hearings and that at least five of the nine judges have to agree in order to declare a law unconstitutional. There is no deadline for the court to issue a ruling, and it cannot be appealed to the U.S. Supreme Court because the issue deals strictly with Puerto Rico's constitutional law, he said.

If the court finds in favor of the Senate, Justice Secretary Wanda Vázquez would become governor, Ramos said, adding that it's unclear whether Pierluisi could remain as secretary of state or whether he would be stripped of all positions.

"That's a very technical issue," he said.

Pierluisi was named secretary of state, the next in line to be governor, in a recess appointment last week. The island's House of Representatives then confirmed him to the position in a 26-to-21 vote on Friday, a move he argues makes him the replacement for Gov. Ricardo Rosselló.

However, the Senate had not yet voted on the appointment, and it was expected to do so Monday afternoon.

Pierluisi said in a statement that there is no time to lose.

"Although it is regrettable that this matter has to be elucidated in our courts, I hope that it will be treated with the greatest urgency and diligence for the good of the people of Puerto Rico," he said.

The Supreme Court's announcement means that a hearing scheduled for early Monday evening by the Superior Court of San Juan has been cancelled. The Senate originally filed the lawsuit late Sunday with the Superior Court of San Juan but then asked the Supreme Court on Monday to take the case.

Rosselló formally resigned on Aug. 2 following nearly two weeks of popular protests amid anger over corruption, mismanagement of funds and a leaked obscenity-laced chat in which he and 11 other men made fun of women, gay people and victims of Hurricane Maria, among others.

Puerto Rico's constitution says that the secretary of state has to be approved by both the House and Senate, and that the secretary of state is next in line if the governor steps down. One amendment, however, states that a secretary of state in line to become governor does not have to be approved by both chambers. Legal experts, however, question the amendment's validity and believe Pierluisi must be confirmed by both chambers because the amendment contradicts the intent of the constitution and its statement of motives.

Pierluisi has said the upcoming Senate vote is a moot point because he already is governor, but then on Monday he issued a statement saying he would respect the outcome of their vote.

"The only thing I ask of Senators is that before they make a decision they listen to the people, to whom we are indebted," he said.

If the Senate votes against his appointment as secretary of state, Pierluisi has said he would step down and hand the governorship to the justice secretary, the next in line under the constitution.

Pierluisi has said he spoke by phone on Saturday with Rivera, who is running for governor in the 2020 general election. The Senate president said he has doubts about Pierluisi and insists that a Senate confirmation is necessary.

Further complicating the situation was a lawsuit filed Monday in Puerto Rico's Supreme Court by Carmen Yulín Cruz, mayor of the Puerto Rican capital of San Juan. The lawsuit questions whether Pierluisi had the right to be sworn in on Friday.

The crisis could now drag on for days or even weeks, with legal experts saying Puerto Rico's Supreme Court will likely issue the final decision if the Senate does not approve of Pierluisi as secretary of state and he declines to relinquish his position. A well-respected attorneys' organization has accused Pierluisi of "hijacking" the constitution.

Those who oppose Pierluisi said having him as governor represents a serious conflict of interest because he worked for a firm that represented a federal control board overseeing the island's finances amid a 13-year recession.

During his public hearing on Friday, Pierluisi said he is against several austerity measures sought by the board as Puerto Rico struggles to recover from Hurricane María, including laying off public employees and eliminating a Christmas bonus. But Pierluisi's brother-in-law is chairman of the board that Congress created to oversee the restructuring of some of the more than $70 billion in public debt after Puerto Rico declared a form of bankruptcy.

Pierluisi previously was Puerto Rico's representative in Congress from 2009 to 2017 and then ran against Rosselló in the 2016 primaries and lost. He also served as justice secretary under Rosselló's father, Pedro Rosselló, when he was governor.