You go to TÜV directly when you know/think that your car won´t fail the inspection. Otherwise you bring it to the dealership or an independent garage beforehand (in case of the Tesla or if you want so save money). They will fix the stuff for you and then introduce it to inspection. No matter if you drive a BMW, Dacia or Tesla. And TÜV is not cheaper, they want more or less all the same amount of money.
These statistics of TÜV are not about broken cars, it's about road safety. Broken head lamps, failing breaks, rubbers at suspension is brittle, .... These kind of things. And yes, most(not all) German cars won't fail at these things in the first five or so years. And yes, there were cars with bad transmission (DSG), failing engines and so on, but these problems are not counted in the TÜV statistics.