On my car the emissions laws definitely caused more emissions than they saved that day.
Yes. Combine with the fact some only pass after certain conditions (eg. over 3000 revs for 10 mins, or idle for 5 mins, or only after 3 starts, only when the outdoor temperature is within this range, etc). Sometimes those conditions aren't stated in the manuals.
That makes the checks passing seem more like a random process and driving more will usually make them pass, eventually.
And drivers without a code reader won't know when it has passed, so they are usually instructed by mechanics to drive a long way to be sure before taking it in for a test (don't want to have to reschedule the test just because you didn't drive it enough).
A code reader really pays off sometimes to reset everything :)
If you're fancy, you can even make it a quick-disconnect setup so that if you drive away with it still on, it won't break anything (or do the poor-man's version where you have the wire connected to the wheel chocks).
I'm reminded how often people come to the RV forum trying to figure out parasitic draw. The answer almost always ends up being the propane detector. People forget it's even there.
Less of an issue on newer RVs that come with at least one basic solar panel installed from the factory.