Tesla has benefited from higher oil prices in the past, so it seemed odd that crude was down sharply and the electric-vehicle maker’s stock was up. Oil prices helped most stocks. Hopes of an end to fighting in Iran are responsible for the oil move.