A common thing I\'d like to do is revert my working copy to a particular revision, do some testing, and then bring it back to the head of my current master. In the past I have
Assuming you're already on a branch (which you always should be for changes you want to keep), you can just do
git checkout
This will take you off the topic branch you were working on into (no branch), in which the working copy refers directly to a commit ID rather than a branch name as normal.
Then to move back, simply:
git checkout
A helpful way to think of it is this: git checkout never alters branches; it merely changes what your working copy is currently looking at (ie, HEAD), which might either be a branch (in which case commits will update the branch) or a random commit hash.
As such, as long as the changes you want to keep are on a branch, you don't have to worry about git checkout losing them.