RICHMOND, Va. (AP) -- Ralph Northam has won the Democratic nomination in Virginia's closely watched race for governor, defeating an insurgent challenger backed by U.S. Sens. Bernie Sanders and Elizabeth Warren.

Northam beat former congressman Tom Perriello Tuesday.

The lieutenant governor secured victory thanks in part to his longer time on the campaign trail and fundraising advantage. Northam had the support of the state Democratic Party's core constituencies, including teachers groups and African-American political and religious leaders. Northam had particularly strong support from some abortion rights and gun control groups, advocates from two areas where Perriello had baggage from past votes in Congress.

Protestors briefly stole the spotlight at Northam's primary night celebration when they stormed the stage.

Virginia is one of only two states electing new governors this year, and the contest could serve as a preview to 2018's midterm elections.