(CNN) Democrats are pointing to closer-than-expected results of a House special election Tuesday as the latest evidence that this year's midterms will cement Arizona's status as a marquee swing state.

In a West Valley district that President Donald Trump won by 21 percentage points, Democrat Hiral Tipirneni came just 5 points shy of upsetting Republican Debbie Lesko on Tuesday.

That swing follows a pattern of Democratic gains in statewide and special elections since last year. And if it continues through November, it could mean a sea change in Arizona, where Republicans are defending both retiring Sen. Jeff Flake's seat and Gov. Doug Ducey this fall.

"I was thinking if Hiral could make it a 10-point margin, that would be a victory. To make it 5 -- that is earthshaking," said state Sen. Steve Farley, a leading Democrat in the governor's race. "We are talking about every Republican office going Democrat in the next election if that margin holds up."

Tuesday's contest, more than a month after Democrat Conor Lamb narrowly won a deep-red House seat in the Pittsburgh area, was an opportunity for Democrats to test whether their momentum had spread across the map, and for the GOP to try to fix some of the problems that have plagued the party in recent contests.

Read More