In China, tech-industry leaders and investors hail Elon Musk as a genius and visionary worth cheering on. So it comes as no surprise to them that Tencent, the country’s most valuable company by market capitalization, invested $1.8 billion in his electric-car maker, Tesla.