A familiar fight is playing out in the Democratic primary for Kentucky’s Sixth District on Tuesday: An establishment Democrat is facing off against a newcomer candidate who went viral with her first campaign ad.

The test in KY-6 comes down to who can win over the most Trump voters. The district leans Republican, and many of its rural counties voted for the current president in 2016. But it contains 100,000 more registered Democratic voters. In other words, it’s prime Trump country.

The three candidates vying for the Democratic nomination on Tuesday are Lexington Mayor Jim Gray, retired Marine Lt. Col. Amy McGrath, and state Sen. Reggie Thomas. But the competition has largely boiled down to Gray and McGrath, a young veteran who recently moved back to her home state of Kentucky to run for Congress.

McGrath’s first campaign ad went viral last year, and since then, she’s fundraised more than $2 million. She’s running as a fresh face and campaigning on her lack of political experience — the very thing her opponents are attacking her for.

But it’s clear Gray is taking McGrath and her outsider status seriously. Despite being the establishment pick, he recently said he wouldn’t vote for House Minority Leader Nancy Pelosi if she runs for speaker. (McGrath said she wants to wait and see who’s running.) And he ran his first negative ad on McGrath.

Whoever wins Tuesday’s election will face incumbent Rep. Andy Barr in November, who is uncontested in his primary.

Who are Amy McGrath and Jim Gray?

Gray is a longtime player in Kentucky politics; he unsuccessfully ran for US Senate against Rand Paul in 2016. But he has local credentials and a built-in advantage as mayor of Lexington; about 40 percent of the district’s voters live in Fayette County, where the city is located.

Due to his background and money (Gray is a millionaire), the Democratic Congressional Campaign Committee (DCCC) believes the Lexington mayor will be more competitive against Barr in the fall. The committee reportedly urged the Lexington mayor to enter the race, drawing criticism from McGrath. Gray’s campaign pushed back on these claims, telling the Lexington Herald-Leader he entered the race after being encouraged by locals.

McGrath has argued she’s a change agent who can appeal to disaffected rural voters. She thinks her fresh face and lack of political experience can win her the election.

“Recruiting the same types of big-city, older millionaires is not the future,” McGrath told me in a January interview. “Especially in the Democratic Party, we cannot keep relying on a staple of rich white people, old men, to save the Democratic Party.”

McGrath was born in Kentucky but only recently returned to the state; she spent the past couple of decades serving in the Marine Corps as a fighter pilot. Her first campaign ad highlighting her 20 years of military service went viral. Since then, she’s actually out-fundraised Gray, with $2 million to his $1.3 million, according to campaign finance data.

“We have to have a new generation of leaders,” McGrath said in her interview with Vox. “We have to get back to talking to the working and middle class; we have to have more women.”

Whoever emerges from Tuesday’s primary will face off against Andy Barr, a conservative Congress member. Barr will face a tough election no matter whether McGrath or Gray is running against him; Democrats have already mounted credible challenges to him in past years but fell short on fundraising. That’s different this year; McGrath and Gray are fundraising millions between the two of them. Barr will also have to defend his votes for Obamacare repeal and GOP tax cuts.

McGrath is betting that her anti-establishment brand will carry her to Washington in an election year that’s shaping up to be a Democratic wave. She has the financial resources to get her message out, but she’s still facing questions about her credentials for Congress.

McGrath is running as a political newcomer. Her opponents say she’s a carpetbagger.

Both of McGrath’s Democratic opponents — Gray and Thomas — have tagged her as a carpetbagger. In a recent debate, Thomas noted that McGrath is trying to appeal to rural voters in counties outside of Lexington (the largest, bluest city in the district).

“You’ve positioned yourself as being a non-Lexington running for office, that you represent the people outside of Lexington,” Thomas said during a recent debate. He then listed three communities in rural counties — Bybee, Clay City, and Sharpsburg — and asked McGrath to name the counties the towns are in.

“I don’t know, Reggie, I haven’t been everywhere,” McGrath replied. “And I’m not sure everybody who’s lived here, think about the folks in this audience who’ve lived here for 20 years, have you been to all of those places? Look, the fact is that I served my country, okay. I can’t do both. I can’t live here for 20 years and also be a United States Marine, serving the people of Kentucky.”

In the runup to the Tuesday election, Gray’s campaign released its first negative ad about McGrath, hitting her for recently moving back to the state to run.

SIREN: @JimGrayCongress is airing 1st negative ad of the #KY06 race, hitting @AmyMcGrathKY as a carpetbagger ahead of Tuesday’s primary pic.twitter.com/dOmTsyJpDu — Ally Mutnick (@allymutnick) May 18, 2018

“Now she’s running for Congress to represent the one place she’s never lived: here,” a narrator says on the ad. “In fact, she moved here from Maryland just last year to run for Congress. We honor Amy McGrath’s service, but shouldn’t she live here for a while before she tries to represent us?”

The ad highlights something McGrath is trying to play to her advantage but her opponents see as a weakness. It immediately received pushback from veterans groups like VoteVets and some sitting members of Congress who are veterans, such as Rep. Ted Lieu (D-CA), who demanded Gray take down the ad.

“You can elevate yourself, but don’t attack another Dem,” Lieu tweeted. “One reason @AmyMcGrathKY lived in a different place is because she was serving our nation in Afghanistan & Iraq flying F-18 combat missions. Stop attacking her military service. Take your ad down.”

Dear @JimGrayCongress: You can elevate yourself, but don't attack another Dem.



One reason @AmyMcGrathKY lived in a different place is because she was serving our nation in Afghanistan & Iraq flying F-18 combat missions.



Stop attacking her military service. Take your ad down. https://t.co/0KHvbV5K8i — Ted Lieu (@tedlieu) May 19, 2018

Gray’s ad demonstrates another thing: The Lexington mayor sees McGrath as a serious competitor. Kentucky voters will decide on Tuesday whether they value experience over an outsider.