Film hits and a pitched race for the White House lifted revenues and profits at Time Warner during the third quarter, helping the company beat Wall Street’s expectations.

Revenues at the media conglomerate behind HBO, Warner Bros., and Turner rose 9% to $7.2 billion, while operating income climbed 10% to $2 billion. Earnings-per-share jumped 48% to $1.87 for the three-month period ending in September.

Analysts had been expecting the company to post revenue of just under $7 billion on earnings of $1.37 a share, according to Thomson Reueters.

Time Warner got a boost from “Suicide Squad,” the hit film about a group of super villains, and Clint Eastwood’s “Sully,” as well as stronger advertising and subscription revenue at Turner, the home of CNN.

The earnings announcement comes two weeks after Time Warner announced that AT&T has a deal in place to buy the company for approximately $85 billion. The potential sale has drawn a great deal of scrutiny, with Republican presidential nominee Donald Trump threatening to scuttle the union and lawmakers in both parties expressing concern that it will consolidate too much power.

In a statement accompanying the earnings results, Time Warner chief Jeff Bewkes hailed the merger as an opportunity to drive long-term value, saying, “Combining with AT&T is the natural next step in the evolution of our business and allows us to significantly accelerate our most important strategies.”

Warner Bros., the company’s film division, has struggled in recent years as major franchises such as “The Hobbit” and “Harry Potter” have come to an end. That time in the wilderness may be coming to an end. Box office returns were a source of the strength during the period. Revenues increased 7% to $3.4 billion on ticket sales, which helped cushion the blow from lower video game results, while operating income increased 11% to $428 million. The studio has big expectations for “Fantastic Beasts and Where to Find Them,” a spin-off of the Potter series that hits theaters in November.

Turner, which also houses TNT and TBS, saw revenues increased 9% to $2.6 billion on stronger subscription and ad sales, while operating income climbed 8% to $1.2 billion. The unit got a ratings lift from CNN, which has been chronicling every scandal and attack associated with the battle between Hillary Clinton and Trump.

At HBO, revenues rose 4% to $1.4 billion despite higher programming costs. Operating income increased 2% to $530 million. During the period, the premium cable network fielded the acclaimed mini-series “The Night Of,” which details a murder investigation, and “Vice Principals,” a comedy series with Danny McBride.

Buoyed by the strong earnings report, Time Warner lifted its forecasts. The company said it expects to earn between $5.73 to $5.83 a share, up from its previous projections of between $5.35 to $5.45.

Shares of Time Warner rose 1.42% in pre-market trading to $89.50.