WASHINGTON — In a stunning rebuke, a dozen defecting Republicans joined Senate Democrats Thursday to block the national emergency that President Donald Trump declared so he could build his border wall with Mexico. The rejection capped a week of confrontation with the White House as both parties in Congress strained to exert their power in new ways.

The 59-41 tally, following the Senate’s vote a day earlier to end U.S. involvement in the war in Yemen, promised to force Trump into the first vetoes of his presidency. Trump had warned against both actions. Moments after Thursday’s vote, the president tweeted a single word of warning: “VETO!”

Two years into the Trump era, a defecting dozen Republicans, pushed along by Democrats, showed a willingness to take that political risk. Twelve GOP senators, including the party’s 2012 presidential nominee, Mitt Romney of Utah, joined the dissent over the emergency declaration order that would enable the president to seize for the wall billions of dollars Congress intended elsewhere.

“The Senate’s waking up a little bit to our responsibilities,” said Sen. Lamar Alexander, R-Tenn., who said the chamber had become “a little lazy” as an equal branch of government. “I think the value of these last few weeks is to remind the Senate of our constitutional place.”

Many senators said the vote was not necessarily a rejection of the president or the wall, but protections against future presidents — namely a Democrat who might want to declare an emergency on climate change, gun control or any number of other issues.

“This is constitutional question, it’s a question about the balance of power that is core to our constitution,” Romney said. “This is not about the president,” he added. “The president can certainly express his views as he has and individual senators can express theirs.”

West Virginia Senators were split on the emergency declaration wanted by Pres. Donald Trump.

Sen Joe Manchin (D-W.Va.) released the following statement on his decision to vote for the emergency declaration resolution of disapproval.

“I will vote for the emergency declaration resolution of disapproval, overturning the President’s national emergency declaration on border security,” he said. “Let me be clear, I support total border security, which includes building a wall on our southern border. However, I believe that those funds, according to the Constitution, need to be appropriated through Congress, not through executive authority.”

Manchin quoted the late Sen. Robert Byrd to support his stance:

‘The absolute bedrock of the people’s continued freedom from tyranny and excesses of all types of authority is, again, anchored in the pages of history. It is the power of the purse. This essential tool—control of the purse by the people’s representatives in Congress—lies at the very foundation of our freedoms. I believe that it is the fulcrum of the people’s leverage. This control of the purse is one of the most effective bulwarks ever constructed to repel a despot, control a tyrant, or shackle the hands of an overreaching executive. Chip away at this fundamental barrier and one chips away at the very cornerstone of the people’s liberties.’

“Regardless of who the President is, Congress has an obligation to defend the Constitution,” Manchin said. “That is why I oppose the President’s decision to unilaterally declare a national emergency. I fought President Obama’s executive overreach when he was in office, and I will do the same today with President Trump because I believe in the Constitution of the United States with all of my heart.”

Sen. Shelley Moore Capito (R-W.Va.), who is chair of the Homeland Security Appropriations Subcommittee, sided with the President on the issue.

“There is no doubt that we are facing a serious security and humanitarian crisis at our southern border, and as news reports and data from the Department of Homeland Security have shown in recent weeks, that crisis is only getting worse,” she said in a statement. “As chair of the Homeland Security Appropriations Subcommittee, I’ve worked with the President, administration officials, and my colleagues in Congress to provide resources that will help strengthen our border security. A few weeks ago, we came to a bipartisan funding agreement that made a significant down payment on the president’s border security goals, but it’s become clear that more needs to be done. That’s why I support the president’s decision to declare a national emergency at our southern border and why I voted to uphold that decision today.”

Capito said this action is within the purview of the President.

“Congress gave the President the power to take such action in order to provide for our national security and keep Americans safe, so this isn’t about whether or not the president is acting within his rights or about the separation of powers,” she said. “This vote was about whether or not we agree that there is a crisis at the southern border and whether or not we believe the president should have the tools to fix it. I, for one, support the president in his efforts to strengthen our border security and address the situation at the border, and I was proud to vote to uphold his emergency declaration.”