The race will determine whether Brazil joins a regional rightward shift that has seen conservative allies of the U.S. President win in Chile, Colombia and Peru.