I'm not sure how it's handled now, but what I'd like to see is after the election closes, a random method to select poll locations is used -- such as a lottery ball machine -- and those locations are then required to do a manual recount. No one has advance notice of which poll locations will do this, so there's no opportunity for cheating (eg, turning off a defeat device at the locations that will be audited).
If there are any differences in the count then additional locations are required to also do a manual count, and if more than two locations have differences, all electronic numbers are trashed and the whole election is counted manually.