Stock markets in Toronto and New York ended Thursday moderately higher as political and economic news dominated the headlines.

The S&P/TSX composite index climbed 50.95 points to 15,423.09, helped by gains in the metals and financials sectors. The lift also helped offset losses in the gold sector, the biggest decliner.

One of the biggest movers of the day were shares in Valeant Pharmaceuticals. Its stock rose after the Quebec-based drug company announced it was selling its iNova unit for US$930 million in cash. Valeant says it plans to use the proceeds of the sale to repay debt. Its shares gained 9.38%, or $1.54, to $17.96.

On Wall Street, the Dow Jones industrial average added 8.84 points to 21,182.53 while the S&P 500 index advanced 0.65 of a point to 2,433.79. The tech-heavy Nasdaq composite index jumped 24.38 points to 6,321.76, a new record high.

The gains came amid testimony by former FBI director James Comey about Russia’s possible meddling in the U.S. election, a monetary policy meeting of the European Central Bank and the U.K. election.

Markets have been on edge ahead of these major events because the potential negative impact they could’ve had, but by the end of the session, it seemed there was little reaction to the news.

“It’s exceptionally difficult for investors to make asset locations based on highly uncertain political events, whether that’s the U.K. election or political testimony in Congress,” said Todd Mattina, chief economist and strategist at Mackenzie Investments.

“Very few investors can reliably make money from these types of political risk events. Today’s lack of action affirms that many investors anticipated potential large moves that didn’t happen. We saw that with the Brexit decision and we saw that with the surprise election of Donald Trump, that these risk events don’t always lead to the outcomes that investors expect.”

In his testimony, Comey’s first public statements since his May 9 dismissal, he told Congress that the Trump administration spread “lies” about him and the FBI after his abrupt firing in May. The stock indexes continued to trade in a narrow range throughout the hearing, the public portion of which wrapped around midday.

Mattina said perhaps there was so little market reaction because Comey’s testimony didn’t reveal a “smoking gun” or anything that would point to any legal wrongdoing by Trump.

Overseas, the ECB announced it was keeping its stimulus program unchanged, even though risks to the European economic recovery have diminished.

Commodities were mixed as the July crude oil contract lost US8¢ at US$45.64 per barrel and the July natural gas contract moved ahead a penny at US$3.03 per mmBTU.

The August gold contract was down US$13.70 to US$1,279.50 an ounce and the July copper contract gained US6¢ at US$2.61 a pound.

The Canadian dollar lost 0.06 of a cent to an average trading price of US74.06¢.

With files from The Associated Press