The House of Representatives on Thursday night voted to approve a temporary spending bill that includes $5 billion in funding for a Mexico border wall, bringing the country closer to a partial government shutdown.

The Republican-controlled House approved the bill by a vote of 217 to 185 along party lines.

The House bill will now be sent to the Senate, where it will need Democrat support and will likely not pass. Government funding for a number of departments will expire at midnight on Friday without a resolution, leading to a shutdown.

Despite the long odds, President Trump celebrated the vote in a tweet hours after the bill cleared the House.

“Thank you to our GREAT Republican Members of Congress for your VOTE to fund Border Security and the Wall,” Trump wrote. “The final numbers were 217-185 and many have said that the enthusiasm was greater than they have ever seen before. So proud of you all. Now on to the Senate!”

The vote came after Trump said Thursday that he would refuse to sign a spending bill that didn’t have funding for a wall on the Mexico border, such as the bill that passed the Senate on Wednesday.