Fiorina ran unsuccessfully for the United States Senate in 2010 and the Republican presidential nomination in 2016. Fiorina was an adviser to Republican Senator John McCain's 2008 presidential campaign. In 2010, she won the Republican nomination for the United States Senate in California, but lost the general election to incumbent Democrat Barbara Boxer. Fiorina was a candidate in the 2016 Republican presidential primary, and was for seven days the vice-presidential running mate of Ted Cruz until he suspended his campaign, setting the record for shortest vice presidential candidacy in modern U.S. history.