Well, the idea is that instead of logging into production, you log into your development environment, do the testing there--then you write a script that replicates what you just did. Lastly, you run the script on staging, and if that seems to work, then run it on production.
There's a pretty handy tool I use now (fabric: docs.fabfile.org) that makes it pretty simple.