Senate Democrats, in a preview of the tactics Democrats plan to deploy against incoming president Donald J. Trump, came within two votes of shutting down the federal government in the name of the union coal miners, whose health and pension benefits lose federal support at the end of the year late Friday night.

Funding for the federal government expired midnight Dec. 9 and the House approved its version of a new continuing resolution, 345-to-96.

The Senate needed to approve the House language or force the House members to return to Washington to approve the Senate’s language or cobble together a new bill along with Senators in conference.

It is difficult to overemphasize the institutional pressures working against not passing the House version, if only to consider the time it would take for congressmen to return from their districts and assemble.

The Senate voted 61-to-38 to end debate and 63-to-36 to pass the House bill without the renewed benefits for the coal workers. President Barack Obama signed the new funding bill that carries funding forward virtually unchanged through April at or around 2:00 .a.m.–ending the final government shutdown of his turbulent presidency two hours on.

In the Senate every bill goes through a two-vote process. The first vote is to end debate, which requires 60 votes. The second vote is on the actual approval-disapproval of the motion, which is decided by a simple majority. Often, the real battle over legislation is centered on the first vote. An effort to keep debate extended and delay or even block the second vote is called a “filibuster.”

The vote to end Senate debate was called at 10:00 p.m., but it was not final until an hour or so later. The word had been that Senate Democrats had given up their battle to extend federal support of coal worker pension and health benefits after they were pressured by their Democratic colleagues to beat retreat and allow everyone to go home.

But, 15 minutes into the 15-minute vote there were 30 votes against closing debate and not yet 60 in favor, and the second-ranking Republican, Minority Whip Sen. John Cornyn was quietly standing at a clerk’s table in the chamber’s well. There the tall Texan counted and recounted the tally, while Democrats huddled around Sen. Charles E. Schumer (D.-N.Y.) at clerk’s table on their side of the well. With the clock stopped at 00:00:00, senators continued to pour in as if they had been told their votes were not needed.

In a similar situation, Republican leaders sent for a reclining Sen. Rand Paul (R.-Ky.), who came onto the floor and cast his vote at the well dressed in his slippers and pajamas.

This night, there were no senators in bedclothes, but Trump’s choice for attorney general Sen. Jefferson B. “Jeff” Sessions (R.-Ala.) and one of Trump’s top campaign surrogates Sen. David A. Perdue Jr. (R.-Ga.) walked out of the elevator together and entered the Senate chamber still bundled up in their heavy wool overcoats 30 minutes into the vote to end debate.

As Schumer coached his players on what to do next, the absent man was Minority Leader Sen. Harry Reid (D.-Nev.). Schumer is Reid’s designated successor in the next congressional session. During past battles, it was Reid holding court, looking at his shoes and speaking in hushed tones,while he anxiously rolled together four or five pencils in his hands. For most of the night, Reid was off the floor.

Slight and wiry, Reid was unbending in his determination to support or oppose, and when he did agree to relent, it was only after extracting big promises from the Republicans that he never let them forget.

Schumer is a schmoozer. While Reid would stay on his side of the aisle as if held back by a force field, Schumer glides across to the Republican desks and works over the GOP senators with handshakes, pats on the back, and small jokes meant to both persuade and flatter.

Reid and Obama bonded during the president’s brief tenure in the upper chamber and they shared a tenaciousness, a willingness to stick it out, to call bluffs, ignore ultimatums, and let events play out longer than most Washington operators were used to or could tolerate. During the partial shutdown of the federal government in October 2013, Reid and Obama did not seem to care if it would ever end, as Republicans flailed for a narrative.

Now, it is Schumer’s turn. Schumer does not hold out. He thrusts and parries and then, he cuts his best deal and moves on. It was Schumer, who led Senate efforts to restrict gun rights and grant amnesty to illegal aliens, but he cut his losses. He championed the president’s health care reform, but since he recognized it was political poison, he talks as if he opposed the bill from the start.

With the fight over the benefits for coal miners, Schumer flipped the script on the Republicans.

Another tactic of Schumer’s is to delegate fights to someone else. Schumer’s staff does the work, but he finds someone else to take the spotlight, like when he convinced Sen. Marco Rubio (R.-Fla.) to take lead on his amnesty bill.

This time his front man was Sen. Sherrod Brown (D.-Ohio).

“Washington has bailed out banks and billionaires, but now that coal miners and widows need healthcare, Congress is taking a vacation,” said Brown, who was nearly chosen by 2016 Democratic presidential nominee Hillary R. Clinton to by her running mate.

“These hard-working Americans gave their lungs and their backs to power this country. They paid for their healthcare and they were promised it would be there for them. Our refusal to keep that promise is shameful – it’s everything that’s wrong with Washington and it’s why I cannot support this bill,” he said.

Joining Brown was Sen. Joseph Manchin III (D.-W.V.), who famously fronted Schumer’s bill to restrict gun rights in 2013 with Sen. Patrick J. Toomey (R.-Pa.).

Basking in the glow of Trump’s support among the working people, Republicans ignored bills meant to resolve the expiration of coal worker benefits, so much so that Schumer set them up as the bad guys willing to hurt working pe0ple in the middle of the Christmas season. Of the 38 votes to extend debate, 10 were Republicans. Among the Republicans were Toomey and Manchin’s West Virginia colleague Sen. Shelley Moore Capito, and Brown’s other half Sen. Robert J. Portman.

Depending on Louisiana, the GOP is looking at 51 or 52 senators going into the 115th Congress.

All Schumer needs to beat the Republicans is three or four turncoats–and before the new Congress starts, he picked up 10.