A federal judge heard arguments from both sides on Friday, the day after Comey's legal filing. "Hard to protect my rights without being in contempt, which I don't believe in", Comey said in a tweet. "This is the closest I can get to public testimony", he said.
A judge had been set to issue a ruling on Comey's request to quash the subpoena and halt congressional proceedings - a request that has never previously been granted by a judge in the United States.
Former FBI director James Comey has come to an agreement with House Republicans to testify behind closed doors before the House Judiciary Committee about his actions during the Hillary Clinton email and Russian collusion investigations.
Former FBI Director James Comey wrote on Twitter that he will testify privately before a House panel Monday on the condition that he will be able to speak freely afterward and that a public transcript will be released within 24 hours. "Mr. Comey should agree to these terms and see that we have the same objective, which is to find the truth and seek transparency".
Trump fired Comey in 2017.
"I have just offered to Director Comey that the Committees will publicly release the transcript of his testimony following the interview for our investigation".
Because of the deal, Comey has agreed to withdraw his challenge to the subpoena.
Republican lawyers said they wanted to secure Comey's testimony ahead of a report that the committees are planning to release in the coming weeks.
Early on Sunday, two days after Comey's attorney conceded in court that no federal trial judge had ever batted down a House subpoena, the former Federal Bureau of Investigations chief - who was sacked by President Donald Trump in 2017 - withdrew his request. In the new Congress, Democrats take the majority in the House and Representative Jerrold Nadler of NY is likely to be the new chairman.
House Republicans have also subpoenaed former Attorney General Loretta Lynch to testify about whether her conversations with former President Bill Clinton on a Phoenix tarmac influenced the Clinton investigation.
Comey argued that he was willing to appear in a public hearing, but feared that a closed-door session would only give Republicans the ability to selectively leak information about his testimony.