President Trump’s trade war with China, a crucial test of his vow to level the economic playing field, is emerging as a proxy in a contest with former vice presiden t Joe Biden over who can blunt the Asian power’s challenge to U.S. global standing.

As he has escalated a tariff fight with Beijing, Trump has seized on comments Biden made last month that China is “not competition for us” and called him “a dummy” who underestimates the threat posed by its predatory economic practices.

“China is a major competitor,” Trump told reporters this month, blaming the Obama administration with contributing to a U.S. trade deficit that last year reached $420 billion.

The president then cast himself as the one finally standing up to Beijing’s bullying. “China wants to make a deal very badly,” Trump said. “It’s me, right now, that’s holding up the deal.”

Biden responded by calling Trump’s tariff brinkmanship a foolish strategy that has unsettled U.S. allies, which also have been hit with levees, and raised costs for American consumers — a message that campaign aides said resonates with voters who would have to bear the pain of an extended trade war.

Biden framed the competition with China as requiring a different response, focused primarily on boosting domestic investment in technology, science and education.

Attempting to clean up his earlier remarks, Biden used a campaign stop in Davenport, Iowa, last week to emphasize that China is “a serious challenge to us, and in some areas a real threat.”

“You bet I’m worried about China — if we keep following Trump’s path,” Biden told supporters.

The clash presents risks for Trump and Biden, who has taken an early polling lead among the Democratic primary field, and both could see their stances toward Beijing tested this week with the president heading to a meeting of the world’s economic powers and Biden participating in the first debate of the Democratic primaries.

For Trump, the confrontation comes amid signs that the trade war is beginning to dampen U.S. economic growth. The president will participate in a high-stakes bilateral meeting with Chinese President Xi Jinping at the Group of 20 summit in Osaka, Japan, late this week, with some aides hoping he can clinch a deal and move on. Others caution that a flawed agreement would leave him vulnerable to criticism from Democrats.

For Biden, the debate comes amid a growing consensus in Washington that Xi — once viewed by the Obama administration as a potential reformer — is China’s most powerful leader in decades. The Trump administration has won support on Capitol Hill and in the business community for declaring China a malign actor and direct competitor in its national security strategy. Biden’s stance on China could also find him at odds with some of his Democratic rivals who share some of Trump’s views about the threat China poses to American workers, even if they have criticized his negotiating tactics.

The U.S. trade deficit with China rose $121 billion during President Barack Obama’s eight-year term and has increased an additional $73 billion in the past two years under Trump, according to the Census Bureau.

“It sounds to me like Biden’s view of China is about 10 years out of date,” said Bonnie Glaser, a China expert at the Center for Strategic and International Studies.

Biden “seems to fundamentally believe that if we get our house in order we can manage any threats, including China,” Glaser added. “He’s still not taking seriously the level of cyberthreats and the lack of respect for intellectual property, and the clear evidence China is trying to push the U.S. military out of the region.”

As vice president, Biden courted Xi in the two years before he replaced Hu Jintao in 2013. Biden’s aides emphasized that the Obama administration won cooperation from Beijing on the Paris climate accord and the Iran nuclear deal. And they pointed to the Trans-Pacific Partnership, a 12-nation trade agreement that was envisioned as a hedge against China’s economic clout.

Trump withdrew the United States from all three pacts.

“What I take issue with is the idea that Trump is tough,” said Ely Ratner, who served as Biden’s deputy national security adviser. “With the exception of tariffs, which in and of themselves are highly questionable as a tactic, how is he being tough on China? He’s berating allies. He’s not emphasizing human rights. He’s not taking actions that can be understood in the context of a strategic competition.”

Those contradictions are reflected in an internal White House debate over a speech Vice President Pence postponed early this month that was billed as condemnation of China’s human rights abuses, including the jailing of more than a million Uighur Muslims in “reeducation camps.” The administration also has reportedly held off on corresponding economic sanctions over concerns that it would antagonize Beijing during the trade talks.

Trump also has declined to take sides on the mass demonstrations in Hong Kong protesting a proposed law that would allow criminal suspects to be extradited to the Chinese mainland. By contrast, Biden cited the “extraordinary bravery” of the protesters and said in a tweet, “All of us must stand in support of democratic principles and freedom.”

Aides said that Biden views the Chinese system as structurally flawed and that his remarks last month — during which he cited rampant “corruption” in Beijing and played down the threat from China — reflected his belief that the United States’ democratic ideals and ingenuity will prevail.

“Trump’s view, which is at the heart of MAGA, is that America is weak, that America is a victim,” said Daniel Russel, a vice president at the Asia Society who served as a high-level policy official in the Obama administration. “Biden’s view is the opposite. He’s bullish: America is big. America is strong. We’re great right now.”

Trump’s allies have seized on a new book by the conservative journalist Peter Schweizer to offer another explanation for what they called Biden’s soft stance on China.

The book, “Secret Empires: How the American Political Class Hides Corruption and Enriches Family and Friends,” details financial ties between China and a company in which Biden’s son Hunter is an investor. The company reportedly received the financial support shortly after Hunter accompanied his father on a 2013 trip to Beijing.

Representatives for Hunter Biden have said he was not involved with the company while his father was vice president, and Joe Biden’s campaign aides said there is no evidence that the former vice president acted improperly.

Since his 2016 campaign, Trump has cast China as a hostile actor that for years manipulated its currency and pilfered trade secrets from U.S. companies on its path to becoming the world’s second-largest economy.

Trump played host to Xi at his Mar-a-Lago resort in early 2017 and won cooperation on North Korea sanctions. But the president has grown increasingly frustrated with Beijing on trade. Last month, U.S. officials accused Beijing of reneging on commitments to relax restrictions on American companies, and Trump followed through on a threat to raise tariffs from 10 percent to 25 percent on $200 billion worth of Chinese goods.

China “took us for suckers, and that includes Obama and Biden,” Trump said at a campaign rally in Orlando last week.

Mansfield Foundation President Frank Jannuzi, a former Senate aide for Biden, acknowledged that the public mood is “aligned with Donald Trump in being impatient for China to play by the rules.” But he said Trump’s trade war is likely to win only “short-term concessions” rather than deeper structural changes.

Hudson Institute analyst Michael Pillsbury, an unofficial Trump adviser, countered that Biden subscribes to an outdated theory that China’s state-backed economic system will collapse, despite evidence that it has consistently surpassed projections and taken the lead in some cutting-edge technology.

Trump “has a sense that America is being ripped off by China,” Pillsbury said, “and he was elected to fix it.”