WASHINGTON — Time and again — when President Trump stood by Saudi Arabia after the killing of a Virginia-based journalist, when it looked as if he might intervene in the special counsel’s Russia investigation and when he threatened to declare a national emergency to pay for his border wall — lawmakers on Capitol Hill warned him not to push them too far.

This week, in a remarkable series of bipartisan rebukes to the president, Congress pushed back.

On Wednesday, with seven Republicans breaking ranks, the Senate joined the Democrat-led House in voting to end American military aid to Saudi Arabia’s war in Yemen in protest over the killing of Jamal Khashoggi, a columnist for The Washington Post. On Thursday morning, the House voted unanimously on a nonbinding resolution to make public the findings of the special counsel, Robert S. Mueller III.

And on Thursday afternoon, 12 Republican senators abandoned the president to pass legislation, already adopted by the House, that would block Mr. Trump from declaring a national emergency to build his border wall — an act of defiance that he has vowed to overturn with the first veto of his presidency.

“We’re saying today, ‘No, we do not acquiesce to this,’” Senator Lisa Murkowski, Republican of Alaska, said after voting to block the emergency declaration. “We do not agree that the president should be able to come in and go against the express intention of the Congress when it comes to these appropriated funds” for his wall.