The Republican-controlled Congress narrowly voted against constraining President Donald Trump’s war in Iran.