(CNN) President Donald Trump shocked Republican leadership in an Oval Office meeting Wednesday when he backed a deal pushed by Democrats to attach hurricane relief money to a shorter-term bump in the debt ceiling as well as keeping the government open.

Senate Majority Leader Mitch McConnell and House Speaker Paul Ryan were "blindsided" by the decision , a Republican official told CNN. In fact, hours before Trump agreed to Democrats' proposal, Ryan had publicly called such a plan "ridiculous" during a news conference. The GOP leaders had no heads up or warning that Trump's decision would happen, Republican officials told CNN. Another senior GOP source described the two leaders as "shell-shocked."

Trump's onetime campaign rival, Sen. Ted Cruz, on the other hand, may not have been so surprised.

During the 2016 Republican primary, Cruz frequently cast Trump as a businessman eager to wheel and deal with Democrats, often specifically name-checking Democratic leaders Chuck Schumer and Nancy Pelosi, who were both in the room with Trump Wednesday. This line of argument was key for campaign trail Cruz as he made his case as the "consistent conservative" in the crowded Republican primary field, framing Trump as another "Washington establishment" politician.

Cruz expressed some frustration with the deal in a statement Thursday.

"It is unfortunate that congressional leadership and the administration chose to tie Harvey relief to short-term extensions to the CR and the debt ceiling," he said.

He added: "Historically, the CR and debt ceiling have proven to be the only effective leverage for meaningful spending reform, and I believe we should continue to use them as tools to reduce our long-term debt. I would have much preferred a clean Harvey relief bill — which would have passed both Houses nearly unanimously."

Speaking at the millennial-focused "Life of the Party" forum at St. Anselm College in Manchester, New Hampshire, weeks before the 2016 New Hampshire primary, Cruz blasted his then-opponent.

"Donald, just a couple of days ago, drew the difference between me and him, and he said look, Ted won't go along to get along, he won't cut a deal. So, if as a voter you think that what we need is more Republicans in Washington to cut a deal with Harry Reid and Nancy Pelosi and Chuck Schumer, then I guess Donald Trump is your guy," Cruz said, casting Trump as someone who would continue the "cronyism" and "corruption of Washington."

Weeks later on February 10, the field narrowed as opponents Carly Fiorina and Chris Christie suspended their campaigns. Cruz appeared on Fox's The Kelly File that evening, alluding to Trump as "another dealmaker."

"What I think the race is going to come down to, it's simply going to be, who do the voters trust? We have been burned over and over again. We keep winning elections and the people we elect don't do what we want. And I don't think the conservatives of South Carolina want to nominate another dealmaker, someone who's going to cut deals with Reid, Pelosi, Obama, someone who's going to surrender and capitulate and give in on their principles," he said, adding, "I think what they're looking for is someone who is a consistent conservative, stands for Constitution and Bill of Rights, stands with working men and women of this country."

And just one day before he suspended his presidential campaign, Cruz crossed the street at a Marion, Indiana, campaign stop alongside then-Gov. Mike Pence to speak with a Trump-supporting protester, an interaction that went viral.

.@tedcruz crosses the street to debate Trump supporter: "Trump is deceiving you. He is playing you for a chump." pic.twitter.com/VQbjiroEem — Betsy Klein (@betsy_klein) May 2, 2016

"I will tell you this: if Trump becomes president, he has said on the Supreme Court, he is going to cut a deal with Chuck Schumer," he told the protester. "Trump is a New York liberal who is lying to you and taking advantage of you."

Cruz had a fraught relationship with Trump through the duration of the 2016 campaign, ultimately endorsing his candidacy after telling Republicans to "vote your conscience" at the Republican National Convention in Cleveland. Cruz has since dined with Trump and their wives at the White House and most recently appeared alongside the President as he toured a hurricane shelter in Houston.

Trump's bipartisan dealmaking has put Republican lawmakers, including Cruz, in a difficult spot , complicating their efforts to advance the President's agenda through legislation.

"Trump just killed tax reform," one GOP Senate aide told CNN.

"Now nothing will get done between now and Dec. 15. You think people will vote for a budget now?" the aide asked, referencing the Democrats' proposed deadline for a resolution to fund the federal government.