When these things were originally being tested, at least the Waymo ones I'm familiar with, there was a driver who could manually override in case of issues. Honestly, if these things still have issues with emergency situations (and other unexpected situations), they absolutely still need a driver with the ability to manually override the car. That way, they can still test the self-driving function while being able to actually maneuver the car out of the way of things like this.