Decompose AsUser into public methods: InitiateUserContext and RestoreUserContext

[#63153148]

Signed-off-by: Eric Malm <emalm@pivotallabs.com>
Add bin/test for consistency with other golang projects

Signed-off-by: Eric Malm <emalm@pivotallabs.com>