It has never happened to me, and I have crossed borders 100+ times, mostly Europe to UK and South Africa. Worst is Israel, and their checks were believably focused on finding explosives.
It’s important for people to know that such behavior is not the norm among civilized countries.