I don’t suggest trying that with the deputy if you’re stopped. You’ll probably be Tazered, or beaten senseless, or both.
If I’m walking along the sidewalk, and the deputy does that for failure to produce a photo ID, I’ll also get a nice fat check from the city for my trouble.
If its about refusing a voluntary search by an LEO...I have always done it and only once did a cop force the issue. 6 months later he was not a cop in that department anymore, my complaint was far from his first, and there were lots of witnesses.
Probable cause is basic requirement for any forced search, with or without a warrant. Refusing voluntary searches is well within your rights. Most cops will push after the first ‘no” and will back off once they realize you are well informed as to your rights. Tarrying with you takes them off the streets and they know that in the long run that is not the right thing to do.