The Senate on Thursday easily cleared a two-week stopgap funding bill, one day before the deadline to avoid a government shutdown.

Senators voted 81-14 on the legislation, which cleared the House earlier in the day.

The bill now heads to the White House, where President TrumpDonald John TrumpFacebook releases audit on conservative bias claims Harry Reid: 'Decriminalizing border crossings is not something that should be at the top of the list' Recessions happen when presidents overlook key problems MORE is expected to sign it.

Six Republicans, seven Democrats and Sen. Bernie SandersBernie SandersHarry Reid: 'Decriminalizing border crossings is not something that should be at the top of the list' The exhaustion of Democrats' anti-Trump delusions Warren offers plan to repeal 1994 crime law authored by Biden MORE (I-Vt.) voted against the legislation. 

Congress had until the end of Friday to pass a bill or spark a government shutdown — something GOP leadership has been adamant they would not let happen while they control the levers of power in Washington.

Lawmakers now face another deadline on Dec. 22, setting up a funding showdown just three days before Christmas.

Top GOP senators urged their colleagues to support the legislation despite grumbling among some in the caucus about the impact a continuing resolution has on military spending.

“We need this legislation to give Congress and the administration additional time to agree on responsible spending levels for the current fiscal year and beyond. ... I hope the Dec. 22 backstop will facilitate an agreement that will enable the Congress to provide funding for important national security and domestic priorities,” Sen. Thad CochranWilliam (Thad) Thad CochranBiden has a lot at stake in first debate The Hill's Morning Report — Trump turns the page back to Mueller probe Trump praises Thad Cochran: 'A real senator with incredible values' MORE (R-Miss.), chairman of the Appropriations Committee, said shortly before the Thursday evening vote.

Majority Leader Mitch McConnellAddison (Mitch) Mitchell McConnellPelosi, Schumer press for gun screenings as Trump inches away The malware election: Returning to paper ballots only way to prevent hacking First House Republican backs bill banning assault weapons MORE (R-Ky.) said the stopgap measure would “provide us with the time we need to complete discussions on a long-term solution.”

But Sen. John McCainJohn Sidney McCainMcCain's family, McCain Institute to promote #ActsOfCivility in marking first anniversary of senator's death Arizona poll shows Kelly overtaking McSally 3 real problems Republicans need to address to win in 2020 MORE (R-Ariz.), the chairman of the Armed Services Committee, said it was "unacceptable" that Congress was passing the stopgap bill.

"I have implored Congress and the White House to negotiate a bipartisan budget agreement, because without one, the military will be funded under a Continuing Resolution at the Budget Control Act levels," he said.

Senate Republicans can’t pass a government funding bill on their own, and needed consent from Democrats to speed up debate of the legislation to meet Friday’s deadline.

Democratic leadership remained tight-lipped throughout the week about if they would support a continuing resolution as they looked for leverage in negotiations on a final, year-end spending package. 

“I don’t know. I think this is likely to pass,” Sen. Dick DurbinRichard (Dick) Joseph DurbinSenate Democrats push Trump to permanently shutter migrant detention facility House panel investigating decision to resume federal executions To combat domestic terrorism, Congress must equip law enforcement to fight rise in white supremacist attacks MORE (D-Ill.) told reporters in the lead up to Thursday’s vote.

Negotiators are hoping to get a deal on the budget caps before the Dec. 22 deadline. 
 
An agreement would likely allow lawmakers to pass another continuing resolution into January and use the time to craft a "omnibus" spending bill that would fund the government through the rest of the 2018 fiscal year. 
 
If lawmakers aren't able to get a deal on the budget, sequestration is set to start in mid-January, which will spark automatic spending cuts. 
 
 
McConnell told reporters after the meeting that they did not reach an agreement, with Schumer and Pelosi offering a similar take in a joint statement. 
 
“We had a productive conversation on a wide variety of issues. Nothing specific has been agreed to, but discussions continue," they said. 
 
Democrats want an equal increase in defense and nondefense spending, as well as an extension of the Children's Health Insurance Program (CHIP) and a legislative fix for the Deferred Action for Childhood Arrivals (DACA) program. 
 
The Trump administration announced earlier this year that it was nixing DACA, which allows immigrants brought into the country as children to live and work. The program will expire in March. 
Trump's move has sparked a legislative showdown in the Senate.
 
Democrats, who say the issue needs to be dealt with by the end of the year, want Republicans to pass a deal that links the Development, Relief, and Education for Alien Minors (DREAM) Act with border security. 
 
Republicans, and the White House, counter that an immigration deal will not be included in the funding bill. 

Sen. James LankfordJames Paul LankfordHillicon Valley: GOP hits back over election security bills | Ratcliffe out for intel chief | Social media companies consider policies targeting 'deepfakes' | Capital One, GitHub sued over breach The Hill's 12:30 Report: Biden camp feels boost after Detroit debate GOP punches back in election security fight MORE (R-Okla.), who introduced legislation that would include a path to citizenship, said on Thursday that lawmakers didn't have time to reach an agreement by the end of the year. 

"There's too many outstanding issues. ... There's not enough time to build the coalitions to get a result by the end of the year," he said. 

In addition to Sanders and McCain, the senators who voted against the stopgap funding bill were Cory BookerCory Anthony BookerCastro qualifies for next Democratic primary debates Eight Democratic presidential hopefuls to appear in CNN climate town hall Biden, Buttigieg bypassing Democratic delegate meeting: report MORE (D-N.J.), Ted CruzRafael (Ted) Edward CruzGOP strategist predicts Biden will win nomination, cites fundraising strength 3 real problems Republicans need to address to win in 2020 The Hill's Morning Report - Trump on defense over economic jitters MORE (R-Texas), Joni ErnstJoni Kay ErnstErnst town hall in Iowa gets contentious over guns Air Force probe finds no corroboration of sexual assault allegations against Trump pick Gun control activists set to flex muscle in battle for Senate MORE (R-Iowa), Kirsten GillibrandKirsten Elizabeth GillibrandCastro qualifies for next Democratic primary debates The Hill's Morning Report - Trump searches for backstops amid recession worries 2020 Democrats react to NYPD firing of officer in Garner case: 'Finally' MORE (D-N.Y.), Kamala HarrisKamala Devi HarrisHarry Reid: 'Decriminalizing border crossings is not something that should be at the top of the list' Warren offers plan to repeal 1994 crime law authored by Biden Sanders leads Democratic field in Colorado poll MORE (D-Calif.), Mazie HironoMazie Keiko HironoDemocratic senator on possibility of Trump standing up to the NRA: 'That's just such BS' Schumer to Trump: Demand McConnell hold vote on background check bill Graham moves controversial asylum bill through panel; Democrats charge he's broken the rules MORE (D-Hawaii), Mike LeeMichael (Mike) Shumway LeeMcConnell, allies lean into Twitter, media 'war' Conservatives buck Trump over worries of 'socialist' drug pricing Criminal justice reform should extend to student financial aid MORE (R-Utah), Ed MarkeyEdward (Ed) John MarkeyJoseph Kennedy mulling primary challenge to Markey in Massachusetts Overnight Energy: Trump sparks new fight over endangered species protections | States sue over repeal of Obama power plant rules | Interior changes rules for ethics watchdogs To cash in on innovation, remove market barriers for advanced energy technologies MORE (D-Mass.), John McCain (R-Ariz.), Jeff MerkleyJeffrey (Jeff) Alan MerkleySenate Democrats push Trump to permanently shutter migrant detention facility Senate Dem seeks answers from DHS on reports of pregnant asylum seekers sent back to Mexico Schumer backs Pelosi as impeachment roils caucus MORE (D-Ore.), Mike RoundsMarion (Mike) Michael RoundsThe Hill's Morning Report - Progressives, centrists clash in lively Democratic debate Senate braces for brawl over Trump's spy chief Overnight Defense: Esper sworn in as Pentagon chief | Confirmed in 90-8 vote | Takes helm as Trump juggles foreign policy challenges | Senators meet with woman accusing defense nominee of sexual assault MORE (R-S.D.), Ben SasseBenjamin (Ben) Eric SasseThe Hill's Morning Report - Trump lauds tariffs on China while backtracking from more To cash in on innovation, remove market barriers for advanced energy technologies Feds face mounting pressure over Epstein's death MORE (R-Neb.) and Elizabeth WarrenElizabeth Ann WarrenHarry Reid: 'Decriminalizing border crossings is not something that should be at the top of the list' Warren offers plan to repeal 1994 crime law authored by Biden Panel: Jill Biden's campaign message MORE (D-Mass.).

- This story was updated at 6:31 p.m.