What you have is a bad connection, batt to starter or batt to ground.Take a voltage meter not a test light,turn on headlights [this is when you loose voltage] measure across batt, if 12v +/- its good,measure neg term to clean spot on engine if any voltage shows you have bad ground cable. Measure pos term to copper stud on starter solinoid,if voltage there pos cable is bad.
