WASHINGTON, D.C. - A long-term budget deal is now heading to President Donald Trump’s desk.

The Senate passed the deal Thursday, that raises spending $320 billion over current levels. It also suspends the debt ceiling through July 2021.

Nearly two-dozen Republican senators opposed the deal despite demands from President Trump to support it. Trump and Congressional leaders struck the compromise last month, likely averting what would have been the nation’s first-ever debt default next month and possibly another government shutdown this fall.

“I think even our Republican friends realized the government shutdown was so damaging to them and the President that they are going to do everything they can to avoid it,” Senate Minority Leader Charles Schumer (D-N.Y.) said ahead of Thursday’s vote.

Hawaii's U.S. Sens. Mazie Hirono and Brian Schatz, both Democrats, each supported the measure.

“A two-year budget, as I said, lends stability to the budgeting process and appropriation process so that we will lessen the chances of yet another totally unnecessary government shutdown," Hirono said following the vote, in which five of her Democratic colleagues voted against the measure.

U.S. Sen. Pat Toomey (R-Pa.) was one of the Republicans who voted against the deal citing concerns over the deal’s increase of the national deficit and debt.

“Our country is on an unsustainable fiscal path and this budget deal only makes matters worse for taxpayers,” Toomey said in a statement. “And until Congress is willing to make tough spending choices, the national debt will continue to rise and trillion-dollar deficits will be the norm.”

The vote comes as lawmakers head home for the August recess.

The House approved the deal last week with the majority of Republicans defecting and voting against the deal.