Nothing changed the rest of the way and the top five finished in those positions.
Gordon, too, was thinking he had a chance until Kurt Busch crashed, bringing out the 12th and final caution.
"I obviously didn't want to see a short run there at the end," he said.
The victory made team owner Rick Hendrick's organization the winningest team in Martinsville history with 20, breaking a tie it had with the Petty organization.
Gordon, who was tied with Johnson and Rusty Wallace with seven victories on the 0.526-mile oval, said he knew it would be a tough day when Johnson won the pole for the second race in a row here because of the pit road advantage.
"You give him that No. 1 pit stall here at Martinsville, it's almost impossible," Gordon said.
While Johnson dominated, there were times it looked as if the race might go in another direction.
Matt Kenseth, who has struggled at Martinsville throughout his career, actually passed Johnson for the lead and led for 96 laps.
Mark Martin, driving for the injured Denny Hamlin and equally disdainful of the venue, moved into fourth place after taking a chance and getting just two tires on a pit stop, but then faded quickly.
Martin, mindful of Hamlin's four career victories at Martinsville, finished a disappointing 10th.
"I did not fill Denny Hamlin's shoes, I can tell you that much," he said.
Tony Stewart, who said earlier in the week he thought it would be funny to watch Danica Patrick try to navigate her way around the track, got passed by his rookie driver with 19 laps to go. Patrick finished 12, Stewart 17th.
Follow Hank Kurz Jr. on Twitter at: http://twitter.com/hankkurzjr
Cut pounds of stomach fat every week by using this 1 weird old tip.