The testimony came a day before Mr. Comey was set to make a high-profile appearance before the same committee. Mr. Trump, who abruptly fired Mr. Comey last month, also personally pressured him to back away from the investigation into Mr. Flynn’s foreign ties, according to memos written by Mr. Comey and described to The New York Times. The move has opened Mr. Trump to accusations of obstruction of justice.

Officials are expected to be asked about Trump.

The four top officials testifying on Wednesday before the Senate Intelligence Committee were expected to be asked about their interactions with Mr. Trump amid revelations that he has asked a number of officials and lawmakers about what they could do to minimize the investigations into Russian election interference.

The witnesses include Mr. Coats; Admiral Rogers; Andrew McCabe, the acting director of the Federal Bureau of Investigation; and Rod J. Rosenstein, the deputy attorney general.

The hearing came a day before the same panel was set to hear testimony from Mr. Comey, whom Mr. Trump fired last month amid the Justice Department investigation into Russian election interference. The Senate panel is conducting its own investigation, and its counterpart in the House has its own inquiry.

The purpose of the hearing was to discuss legislation to extend the FISA Amendments Act, which is otherwise set to expire on New Year’s Eve. The N.S.A. spying program authorized under the law has drawn criticism both from civil libertarians and, more recently, from supporters of Mr. Trump who have expressed alarm about leaks of surveillance about Trump associates’ contacts with Russians. In an Op-Ed article published in The Times on Wednesday, President Trump’s Homeland Security adviser, Thomas P. Bossert, said the Trump administration endorsed a bill to make the law permanent without any of the changes privacy advocates have proposed. Congress should “leave the politics of distraction for another day,” he wrote.

In March, Mr. Trump asked Admiral Rogers and Mr. Coats to dispute the existence of evidence of collusion between the Trump campaign and Russian officials in meddling in the election. The Washington Post first reported the president’s request.