The randomized algorithm doesn't need to be perfect, it just needs to present a failure probability << the failure rate from other causes. And it can easily do that, since the failure probability goes down exponentially with the number of iterations of the test.