improve docs and error checking for UserAccountOperations test code